:root {
  --ink: #18212f;
  --muted: #687487;
  --line: #dfe6ee;
  --panel: rgba(255, 255, 255, 0.86);
  --soft: #f5f8fb;
  --blue: #2c7be5;
  --teal: #18a999;
  --coral: #ff7a59;
  --amber: #f6b73c;
  --shadow: 0 20px 60px rgba(35, 55, 90, 0.14);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  min-width: 1120px;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(24, 169, 153, 0.16), transparent 34rem),
    linear-gradient(135deg, #f7fbff 0%, #eef5f3 48%, #fff7f3 100%);
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.landing-page {
  min-height: 100vh;
  color: #f8fbff;
  background:
    radial-gradient(circle at 50% 14%, rgba(44, 123, 229, 0.24), transparent 22rem),
    radial-gradient(circle at 78% 18%, rgba(24, 169, 153, 0.16), transparent 20rem),
    linear-gradient(180deg, #080c16 0%, #0d1220 46%, #101823 100%);
  overflow: hidden;
}

.landing-nav {
  z-index: 10;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 24px;
  align-items: center;
  width: min(1220px, calc(100% - 48px));
  height: 72px;
  margin: 0 auto;
  background: rgba(8, 12, 22, 0.78);
  border-bottom: 1px solid rgba(223, 230, 238, 0.12);
  backdrop-filter: blur(18px);
}

.landing-brand,
.landing-actions,
.hero-actions,
.hero-tags,
.platform-strip,
.billing-toggle,
.stats-row,
.landing-footer,
.landing-footer nav {
  display: flex;
  align-items: center;
}

.landing-brand {
  gap: 12px;
  font-size: 18px;
}

.landing-logo {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: #fff;
  font-weight: 800;
  border-radius: 13px;
  background:
    radial-gradient(circle at 72% 24%, rgba(255, 255, 255, 0.82) 0 3px, transparent 4px),
    linear-gradient(145deg, #1f2025 0%, #0f1013 62%, #32343a 100%);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
}

.wx-brand-mark {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  letter-spacing: 0;
}

.wx-brand-mark::before {
  position: absolute;
  top: 9px;
  right: 9px;
  z-index: 1;
  width: 5px;
  height: 5px;
  content: "";
  background: rgba(255, 255, 255, 0.86);
  border-radius: 999px;
}

.wx-brand-mark::after {
  position: absolute;
  right: 7px;
  bottom: 7px;
  z-index: 1;
  width: 12px;
  height: 12px;
  content: "";
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-left: 0;
  border-top: 0;
  border-radius: 2px 0 4px;
  opacity: 0.86;
}

.landing-nav nav {
  display: flex;
  gap: 30px;
  color: rgba(248, 251, 255, 0.72);
  font-size: 14px;
}

.landing-nav nav a:hover {
  color: #fff;
}

.landing-actions {
  justify-content: flex-end;
  gap: 12px;
}

.ghost-btn,
.glow-btn,
.outline-glow-btn {
  border: 0;
  border-radius: 999px;
}

.ghost-btn {
  height: 40px;
  padding: 0 16px;
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.glow-btn {
  height: 42px;
  padding: 0 20px;
  color: #fff;
  font-weight: 800;
  background: linear-gradient(135deg, #2c7be5, #18a999);
  box-shadow: 0 16px 36px rgba(24, 169, 153, 0.32);
}

.glow-btn.large,
.outline-glow-btn {
  height: 54px;
  padding: 0 28px;
  font-size: 16px;
}

.outline-glow-btn {
  color: #dbeafe;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.hero-section {
  position: relative;
  display: grid;
  justify-items: center;
  min-height: 860px;
  padding: 110px 24px 80px;
  text-align: center;
}

.hero-section::before {
  position: absolute;
  inset: 0;
  pointer-events: none;
  content: "";
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.32) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 96px 96px, 120px 120px, 120px 120px;
  opacity: 0.4;
}

.hero-section > * {
  position: relative;
}

.hero-kicker,
.section-eyebrow {
  display: inline-flex;
  align-items: center;
  width: max-content;
  min-height: 38px;
  padding: 0 18px;
  color: #bfe8ff;
  background: rgba(44, 123, 229, 0.14);
  border: 1px solid rgba(44, 123, 229, 0.32);
  border-radius: 999px;
}

.hero-section h1 {
  max-width: 860px;
  margin: 34px 0 22px;
  font-size: clamp(52px, 7vw, 96px);
  line-height: 0.95;
  letter-spacing: 0;
}

.hero-section h1 span,
.landing-section h2 span {
  color: #75d7ff;
}

.hero-section p {
  max-width: 720px;
  margin: 0;
  color: rgba(248, 251, 255, 0.68);
  font-size: 18px;
  line-height: 1.8;
}

.hero-actions {
  gap: 14px;
  margin-top: 34px;
}

.hero-tags {
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
}

.hero-tags span,
.platform-strip span {
  padding: 10px 16px;
  color: rgba(248, 251, 255, 0.76);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
}

.hero-preview {
  width: min(760px, 100%);
  margin-top: 56px;
  overflow: hidden;
  text-align: left;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.06)),
    rgba(8, 12, 22, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  box-shadow: 0 34px 90px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(18px);
}

.preview-toolbar {
  display: flex;
  gap: 8px;
  align-items: center;
  height: 44px;
  padding: 0 18px;
  color: rgba(248, 251, 255, 0.72);
  background: rgba(255, 255, 255, 0.07);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.preview-toolbar span {
  width: 10px;
  height: 10px;
  background: #ff7a59;
  border-radius: 50%;
}

.preview-toolbar span:nth-child(2) {
  background: #f6b73c;
}

.preview-toolbar span:nth-child(3) {
  background: #18a999;
}

.preview-toolbar strong {
  margin-left: 10px;
  font-size: 13px;
}

.preview-board {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 18px;
  min-height: 330px;
  padding: 22px;
}

.preview-product {
  display: grid;
  align-content: end;
  min-height: 286px;
  padding: 28px;
  color: #fff;
  background:
    linear-gradient(160deg, rgba(44, 123, 229, 0.18), rgba(24, 169, 153, 0.2)),
    linear-gradient(135deg, #142034, #243746 58%, #40362e);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
}

.preview-product small {
  color: #75d7ff;
  font-weight: 800;
  letter-spacing: 0;
}

.preview-product strong {
  display: block;
  margin-top: 12px;
  font-size: 34px;
}

.preview-product p {
  max-width: 420px;
  margin-top: 10px;
  color: rgba(248, 251, 255, 0.68);
  font-size: 15px;
  line-height: 1.7;
}

.preview-side {
  display: grid;
  gap: 12px;
}

.preview-side div {
  display: grid;
  align-content: center;
  min-height: 86px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
}

.preview-side span {
  color: rgba(248, 251, 255, 0.62);
  font-size: 13px;
}

.preview-side strong {
  margin-top: 8px;
  color: #fff;
  font-size: 28px;
}

.platform-strip {
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  max-width: 780px;
  margin-top: 48px;
}

.landing-section {
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
  padding: 92px 0;
  text-align: center;
}

.landing-section h2,
.final-cta h2 {
  max-width: 780px;
  margin: 22px auto 14px;
  font-size: clamp(34px, 4vw, 56px);
  line-height: 1.08;
  letter-spacing: 0;
}

.section-subtitle,
.final-cta p {
  max-width: 720px;
  margin: 0 auto;
  color: rgba(248, 251, 255, 0.64);
  font-size: 17px;
  line-height: 1.8;
}

.step-grid,
.ability-grid,
.solution-grid,
.pay-grid,
.pricing-grid,
.case-grid {
  display: grid;
  gap: 20px;
  margin-top: 48px;
}

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

.ability-grid,
.solution-grid,
.pay-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

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

.pricing-grid-four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 22px;
}

.membership-grid article {
  background: rgba(255, 255, 255, 0.04);
}

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

.step-grid article,
.ability-grid article,
.solution-grid article,
.pay-grid article,
.pricing-grid article,
.case-grid article,
.faq-list details {
  text-align: left;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.16);
}

.step-grid article,
.ability-grid article,
.solution-grid article,
.pay-grid article,
.pricing-grid article {
  padding: 28px;
}

.step-grid article span {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 30px;
  color: #fff;
  font-weight: 800;
  background: #2c7be5;
  border-radius: 999px;
}

.landing-section h3 {
  margin: 18px 0 12px;
  color: #fff;
  font-size: 22px;
}

.landing-section article p,
.faq-list p,
.pricing-grid span {
  color: rgba(248, 251, 255, 0.64);
  line-height: 1.75;
}

.solution-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  color: #75d7ff;
  font-weight: 900;
  background: rgba(117, 215, 255, 0.12);
  border: 1px solid rgba(117, 215, 255, 0.24);
  border-radius: 8px;
}

.solution-grid ul {
  display: grid;
  gap: 10px;
  margin: 20px 0 24px;
  padding: 0;
  list-style: none;
}

.solution-grid li {
  padding: 11px 14px;
  color: rgba(248, 251, 255, 0.78);
  background: rgba(255, 255, 255, 0.06);
  border-radius: 8px;
}

.solution-grid button,
.pricing-grid button {
  width: 100%;
  height: 40px;
  color: #fff;
  font-weight: 800;
  background: linear-gradient(135deg, #2c7be5, #18a999);
  border: 0;
  border-radius: 8px;
}

.pay-section {
  width: 100%;
  padding-right: max(24px, calc((100% - 1160px) / 2));
  padding-left: max(24px, calc((100% - 1160px) / 2));
  background: rgba(255, 255, 255, 0.03);
}

.billing-toggle {
  justify-content: center;
  gap: 10px;
  margin-top: 34px;
}

.billing-toggle button {
  height: 40px;
  padding: 0 18px;
  color: rgba(248, 251, 255, 0.72);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
}

.billing-toggle .active {
  color: #fff;
  background: rgba(24, 169, 153, 0.24);
  border-color: rgba(24, 169, 153, 0.42);
}

.pricing-grid article {
  position: relative;
  display: grid;
  gap: 10px;
}

.pricing-grid article strong {
  display: block;
  color: #fff;
  font-size: 42px;
}

.pricing-grid article.popular {
  border-color: rgba(24, 169, 153, 0.54);
  transform: translateY(-10px);
}

.pricing-grid em {
  position: absolute;
  top: 14px;
  right: 14px;
  padding: 5px 10px;
  color: #05221e;
  font-style: normal;
  font-weight: 800;
  background: #75f0d5;
  border-radius: 999px;
}

.case-grid article {
  display: grid;
  place-items: center;
  min-height: 108px;
  color: #fff;
  font-weight: 800;
  text-align: center;
}

.stats-row {
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 28px;
}

.stats-row span {
  padding: 14px 18px;
  color: rgba(248, 251, 255, 0.72);
  background: rgba(255, 255, 255, 0.06);
  border-radius: 8px;
}

.stats-row strong {
  margin-right: 8px;
  color: #75d7ff;
  font-size: 24px;
}

.faq-list {
  display: grid;
  gap: 12px;
  max-width: 820px;
  margin: 44px auto 0;
}

.faq-list details {
  padding: 18px 22px;
}

.faq-list summary {
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.faq-list p {
  margin-bottom: 0;
}

.final-cta {
  width: min(980px, calc(100% - 48px));
  margin: 60px auto 90px;
  padding: 56px;
  color: #fff;
  text-align: center;
  background:
    linear-gradient(135deg, rgba(44, 123, 229, 0.2), rgba(24, 169, 153, 0.18)),
    rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
}

.final-cta .glow-btn {
  margin-top: 28px;
}

.floating-consult {
  display: block;
  width: max-content;
  height: 46px;
  margin: 0 auto 36px;
  padding: 0 20px;
  color: #fff;
  font-weight: 800;
  background: linear-gradient(135deg, #18a999, #2c7be5);
  border: 0;
  border-radius: 999px;
  box-shadow: 0 18px 38px rgba(24, 169, 153, 0.32);
}

.landing-footer {
  justify-content: space-between;
  gap: 18px;
  width: min(1220px, calc(100% - 48px));
  margin: 0 auto;
  padding: 30px 0 40px;
  color: rgba(248, 251, 255, 0.62);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.landing-footer strong {
  color: #fff;
}

.landing-footer nav {
  gap: 16px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
  padding: 0 34px;
  background: rgba(255, 255, 255, 0.8);
  border-bottom: 1px solid rgba(213, 224, 233, 0.8);
  backdrop-filter: blur(18px);
}

.brand,
.top-actions,
.pane-head,
.task-filter,
.preview-head,
.guide {
  display: flex;
  align-items: center;
}

.brand {
  gap: 14px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  color: #fff;
  font-weight: 800;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  box-shadow: 0 12px 26px rgba(44, 123, 229, 0.24);
}

.brand h1 {
  margin: 0;
  font-size: 20px;
  letter-spacing: 0;
}

.brand p,
.preview-head p,
.upload-field p,
.modal p,
.task-card p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.top-actions {
  gap: 10px;
}

.soft-btn,
.icon-btn,
.avatar-btn,
.primary-btn,
.modal button,
.user-menu button {
  border: 0;
  border-radius: 8px;
}

.soft-btn,
.icon-btn,
.avatar-btn {
  height: 38px;
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--line);
}

.soft-btn {
  padding: 0 14px;
}

.account-chip {
  min-width: 92px;
  color: #0f6b61;
  font-weight: 700;
  background: #eefaf7;
  border-color: rgba(24, 169, 153, 0.34);
}

.recharge-chip {
  color: #8a5200;
  font-weight: 800;
  background: #fff8eb;
  border-color: rgba(255, 177, 66, 0.46);
}

.icon-btn,
.avatar-btn {
  display: grid;
  place-items: center;
  width: 38px;
}

.avatar-btn {
  color: #fff;
  font-weight: 700;
  background: linear-gradient(135deg, var(--blue), var(--teal));
}

.workspace {
  display: grid;
  grid-template-columns: 300px minmax(440px, 1fr) 430px;
  gap: 20px;
  align-items: start;
  min-height: calc(100vh - 76px);
  padding: 20px;
}

.task-pane,
.builder-pane,
.preview-pane {
  min-height: 0;
  background: var(--panel);
  border: 1px solid rgba(215, 225, 235, 0.9);
  border-radius: 8px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.task-pane,
.builder-pane,
.preview-pane {
  display: flex;
  flex-direction: column;
}

.task-pane {
  padding: 16px;
}

.pane-head {
  gap: 10px;
}

.primary-btn {
  height: 40px;
  padding: 0 18px;
  color: #fff;
  font-weight: 700;
  background: linear-gradient(135deg, var(--blue), var(--teal));
  box-shadow: 0 12px 24px rgba(24, 169, 153, 0.2);
}

.primary-btn.is-loading {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
  cursor: progress;
  opacity: 0.88;
}

.primary-btn.is-loading::before {
  width: 12px;
  height: 12px;
  content: "";
  border: 2px solid rgba(255, 255, 255, 0.42);
  border-top-color: #ffffff;
  border-radius: 999px;
  animation: soft-spin 0.8s linear infinite;
}

.pane-head .primary-btn {
  flex: 1;
}

.task-list {
  flex: 0 1 auto;
  max-height: 58vh;
  padding: 14px 0;
  overflow: auto;
}

.task-card {
  display: grid;
  grid-template-columns: 54px 1fr auto;
  gap: 12px;
  width: 100%;
  margin-bottom: 10px;
  padding: 12px;
  text-align: left;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.task-main {
  min-width: 0;
  padding: 0;
  color: inherit;
  text-align: left;
  background: transparent;
  border: 0;
}

.task-card.active {
  border-color: rgba(44, 123, 229, 0.55);
  box-shadow: 0 10px 24px rgba(44, 123, 229, 0.13);
}

.thumb {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  color: var(--blue);
  background: #eef7ff;
  border: 1px solid rgba(44, 123, 229, 0.24);
  border-radius: 8px;
}

.task-card strong {
  display: block;
  margin-bottom: 3px;
}

.task-badge,
.status-pill {
  display: inline-flex;
  align-items: center;
  width: max-content;
  height: 22px;
  padding: 0 8px;
  color: #7b5311;
  font-size: 12px;
  background: #fff3d7;
  border-radius: 999px;
}

.fav-btn {
  color: var(--amber);
  background: transparent;
  border: 0;
  font-size: 18px;
}

.task-filter {
  gap: 8px;
}

.task-filter input,
.task-filter select,
.design-form input,
.design-form textarea,
.design-form select {
  width: 100%;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  outline: none;
}

.task-filter input,
.task-filter select {
  height: 38px;
  padding: 0 10px;
}

.check-line {
  display: flex;
  flex: 0 0 auto;
  gap: 6px;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
}

.builder-pane {
  padding: 18px;
  overflow: visible;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 251, 253, 0.96)),
    var(--panel);
}

.assistant-card {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 14px 14px 16px;
  margin-bottom: 6px;
  background: linear-gradient(135deg, #ffffff, #f8fbff);
  border: 1px solid rgba(44, 123, 229, 0.14);
  border-radius: 8px;
  box-shadow: 0 10px 22px rgba(35, 55, 90, 0.06);
}

.assistant-avatar {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: #fff;
  font-weight: 700;
  background: linear-gradient(135deg, #1b7ee8, #16a085);
  border-radius: 8px;
  box-shadow: 0 12px 22px rgba(44, 123, 229, 0.18);
}

.assistant-card p {
  margin: 0;
  line-height: 1.6;
}

.assistant-card span {
  color: var(--blue);
  font-weight: 800;
}

.design-form {
  flex: 0 0 auto;
  min-height: auto;
  padding: 10px 4px 4px;
  overflow: visible;
}

.design-form label,
.upload-field {
  display: block;
  padding: 12px 0;
  margin-bottom: 0;
  border-bottom: 1px solid rgba(223, 230, 238, 0.72);
}

.design-form span,
.upload-field > span {
  display: block;
  margin-bottom: 7px;
  color: #334155;
  font-size: 13px;
  font-weight: 700;
}

.design-form b,
.upload-field b {
  color: #e04b3f;
}

.design-form input,
.design-form select {
  height: 44px;
  padding: 0 12px;
}

.design-form textarea {
  min-height: 92px;
  padding: 12px;
  resize: vertical;
}

.design-form input:focus,
.design-form textarea:focus,
.design-form select:focus {
  border-color: rgba(44, 123, 229, 0.55);
  box-shadow: 0 0 0 3px rgba(44, 123, 229, 0.1);
}

.upload-dropzone {
  position: relative;
  cursor: pointer;
}

.upload-box {
  display: grid;
  gap: 6px;
  place-items: center;
  width: 100%;
  min-height: 132px;
  padding: 18px;
  color: var(--ink);
  background:
    linear-gradient(135deg, #ffffff, #f7fbff) padding-box,
    repeating-linear-gradient(90deg, rgba(44, 123, 229, 0.44) 0 12px, rgba(24, 169, 153, 0.34) 12px 22px) border-box;
  border: 1px dashed transparent;
  border-radius: 8px;
}

.upload-dropzone.is-dragging .upload-box {
  color: #0f6b61;
  background:
    linear-gradient(#eefaf7, #eefaf7) padding-box,
    repeating-linear-gradient(90deg, rgba(44, 123, 229, 0.8) 0 12px, rgba(24, 169, 153, 0.8) 12px 22px) border-box;
  box-shadow: 0 0 0 4px rgba(24, 169, 153, 0.12);
}

.upload-box small,
.upload-box em {
  color: var(--muted);
  font-style: normal;
}

.compact .upload-box {
  min-height: 82px;
}

.upload-dropzone.has-files .upload-box {
  visibility: hidden;
}

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

.upload-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.upload-cover {
  position: absolute;
  inset: 0;
  margin-top: 0;
  padding: 10px;
  overflow: auto;
  background: #fff;
  border: 1px solid rgba(24, 169, 153, 0.36);
  border-radius: 8px;
  box-shadow: inset 0 0 0 1px rgba(44, 123, 229, 0.08);
}

.upload-cover::after {
  content: "点击空白处继续上传";
  display: block;
  justify-self: end;
  margin-top: 8px;
  padding: 5px 8px;
  color: #0f6b61;
  font-size: 11px;
  font-weight: 800;
  background: rgba(238, 250, 247, 0.94);
  border-radius: 999px;
}

.upload-preview-grid.single {
  grid-template-columns: minmax(0, 1fr);
}

.upload-thumb {
  position: relative;
  min-width: 0;
  margin: 0;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.upload-thumb img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: #f8fafc;
}

.upload-thumb.wide img {
  aspect-ratio: 16 / 9;
}

.upload-thumb figcaption {
  display: grid;
  gap: 2px;
  padding: 8px;
}

.upload-thumb strong,
.upload-thumb span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-thumb strong {
  color: #243042;
  font-size: 12px;
}

.upload-thumb span {
  color: var(--muted);
  font-size: 11px;
}

.upload-quality-badge {
  display: inline-flex;
  align-items: center;
  max-width: 88px;
  height: 20px;
  padding: 0 7px;
  overflow: hidden;
  color: #4b5563;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: middle;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
}

.upload-quality-badge.is-good {
  color: #166534;
  background: #ecfdf3;
  border-color: #bbf7d0;
}

.upload-quality-badge.is-warn {
  color: #92400e;
  background: #fff7ed;
  border-color: #fed7aa;
}

.upload-quality-badge.is-poor,
.upload-quality-badge.is-error {
  color: #991b1b;
  background: #fef2f2;
  border-color: #fecaca;
}

.upload-quality-badge.is-checking {
  color: #475569;
  background: #f8fafc;
  border-color: #e2e8f0;
}

.upload-thumb button {
  position: absolute;
  top: 6px;
  right: 6px;
  display: grid;
  place-items: center;
  min-width: 42px;
  height: 24px;
  padding: 0 8px;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  background: rgba(17, 24, 39, 0.76);
  border: 0;
  border-radius: 999px;
}

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

.form-action {
  display: grid;
  gap: 7px;
  margin: 18px 0 0;
  padding: 14px;
  background:
    linear-gradient(135deg, rgba(44, 123, 229, 0.08), rgba(24, 169, 153, 0.08)),
    #fff;
  border: 1px solid rgba(44, 123, 229, 0.16);
  border-radius: 8px;
  box-shadow: 0 14px 30px rgba(35, 55, 90, 0.08);
}

.form-action small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
}

.form-action small.is-live {
  color: #0f6b61;
  font-weight: 800;
}

.submit-btn {
  width: 100%;
  height: 52px;
  font-size: 16px;
  box-shadow: 0 16px 30px rgba(44, 123, 229, 0.24);
}

.submit-btn:disabled {
  cursor: wait;
  opacity: 0.72;
}

.muted {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.icon-btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.preview-pane {
  position: relative;
  padding: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 251, 253, 0.96)),
    var(--panel);
}

.guide {
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding: 12px;
  color: #475569;
  font-size: 13px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.preview-head {
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.preview-head h2 {
  margin: 8px 0 0;
  font-size: 24px;
}

.result-stage {
  flex: 1;
  min-height: 0;
  padding: 16px;
  overflow: auto;
  background:
    linear-gradient(135deg, rgba(44, 123, 229, 0.06), rgba(24, 169, 153, 0.08)),
    #fff;
  border: 1px dashed rgba(44, 123, 229, 0.32);
  border-radius: 8px;
}

.result-stage.has-result {
  border-style: solid;
  border-color: rgba(24, 169, 153, 0.45);
}

.result-image-grid {
  display: grid;
  gap: 14px;
  width: 100%;
}

.generated-image {
  display: block;
  width: 100%;
  max-height: calc(100vh - 150px);
  object-fit: contain;
  background: #0f172a;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 8px;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.14);
}

.popover {
  position: fixed;
  top: 68px;
  right: 32px;
  z-index: 20;
  width: 210px;
  padding: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.user-menu p {
  margin: 6px 0 12px;
  color: var(--muted);
  font-size: 13px;
}

.user-menu button {
  width: 100%;
  height: 36px;
  margin-top: 6px;
  text-align: left;
  background: var(--soft);
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.38);
}

.modal {
  position: relative;
  width: min(560px, 100%);
  max-height: calc(100vh - 48px);
  padding: 26px;
  overflow: auto;
  background: #fff;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.modal h2 {
  margin: 0 42px 16px 0;
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: auto;
  min-width: 48px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 700;
}

.modal.is-history-modal h2 {
  margin-right: 0;
}

.modal.is-history-modal .modal-close {
  display: none;
}

.modal.is-help-modal {
  width: min(880px, 100%);
}

.help-doc {
  display: grid;
  gap: 18px;
}

.help-doc-hero {
  display: grid;
  gap: 8px;
  padding: 18px;
  background: #f7f7f7;
  border: 1px solid #e2e2e2;
  border-radius: 8px;
}

.help-doc-hero span {
  color: #74787f;
  font-size: 12px;
  font-weight: 700;
}

.help-doc-hero strong {
  color: #202124;
  font-size: 20px;
  line-height: 1.3;
}

.help-doc-hero p,
.help-doc-grid p,
.help-doc-panel p,
.help-doc-panel li {
  margin: 0;
  color: #60646b;
  font-size: 13px;
  line-height: 1.75;
}

.help-doc-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.help-doc-grid article,
.help-doc-panel {
  display: grid;
  gap: 8px;
  padding: 15px;
  background: #ffffff;
  border: 1px solid #e1e1e1;
  border-radius: 8px;
}

.help-doc-grid b,
.help-doc-panel h3 {
  margin: 0;
  color: #202124;
  font-size: 14px;
  line-height: 1.4;
}

.help-doc-panel ul {
  display: grid;
  gap: 6px;
  margin: 0;
  padding-left: 18px;
}

.help-doc-panel .primary-btn {
  justify-self: start;
}

.support-feedback-form {
  display: grid;
  gap: 14px;
}

.support-feedback-form label {
  display: grid;
  gap: 8px;
  color: #202124;
  font-size: 13px;
  font-weight: 800;
}

.support-feedback-form textarea {
  min-height: 132px;
  line-height: 1.65;
}

.support-feedback-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #7b818a;
  font-size: 12px;
  line-height: 1.5;
}

.support-feedback-meta span:first-child {
  color: #202124;
  font-weight: 800;
}

@media (max-width: 720px) {
  .help-doc-grid {
    grid-template-columns: 1fr;
  }
}

.modal textarea {
  width: 100%;
  min-height: 120px;
  padding: 12px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.modal input,
.modal select {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.modal .primary-btn {
  margin-top: 12px;
}

.auth-form {
  display: grid;
  gap: 12px;
}

.auth-loading-tip,
.auth-hint {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.auth-loading-tip {
  padding: 10px 12px;
  color: #0f6b61;
  font-weight: 800;
  background: #eefaf7;
  border: 1px solid rgba(24, 169, 153, 0.24);
  border-radius: 8px;
}

.auth-switch {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  padding: 4px;
  margin-bottom: 14px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.auth-switch button {
  height: 36px;
  color: #475569;
  font-weight: 800;
  background: transparent;
  border: 0;
  border-radius: 6px;
}

.auth-switch button.active {
  color: #0f172a;
  background: #ffffff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
  color: var(--muted);
  font-size: 13px;
}

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

.code-row {
  display: grid;
  grid-template-columns: 1fr 132px;
  gap: 10px;
  align-items: end;
}

.code-row .soft-btn {
  height: 40px;
}

.phone-code-hint,
.auth-hint {
  color: #0f6b61;
  line-height: 1.6;
}

.login-notice {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: 10px;
  align-items: start;
  padding: 11px 12px;
  color: #475569;
  font-size: 12px;
  line-height: 1.6;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.modal .login-notice input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  padding: 0;
}

.login-notice label {
  min-width: 0;
}

.login-notice-link {
  padding: 0;
  color: #151a21;
  font: inherit;
  font-weight: 760;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  background: transparent;
  border: 0;
}

.legal-notice-doc {
  display: grid;
  gap: 12px;
  max-height: min(68vh, 620px);
  padding-right: 4px;
  overflow: auto;
}

.legal-notice-doc article {
  padding: 12px 14px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.legal-notice-doc h3 {
  margin: 0 0 6px;
  color: #111827;
  font-size: 14px;
  line-height: 1.35;
}

.legal-notice-doc p {
  margin: 0;
  color: #475569;
  line-height: 1.75;
}

.legal-notice-actions {
  position: sticky;
  bottom: 0;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  padding: 12px 0 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.82), #ffffff 36%);
}

.new-user-fields {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: #f8fbff;
  border: 1px solid rgba(44, 123, 229, 0.2);
  border-radius: 8px;
}

.password-strength {
  color: #64748b;
  font-weight: 800;
}

.password-strength[data-score="0"],
.password-strength[data-score="1"] {
  color: #dc2626;
}

.password-strength[data-score="2"],
.password-strength[data-score="3"] {
  color: #b7791f;
}

.password-strength[data-score="4"],
.password-strength[data-score="5"] {
  color: #0f8a73;
}

.auth-form fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.auth-form legend {
  margin-bottom: 8px;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
}

.auth-form label span {
  display: block;
  margin-bottom: 6px;
  color: #334155;
  font-size: 13px;
  font-weight: 700;
}

.demo-login-btn {
  height: 40px;
  color: #075e54;
  font-weight: 800;
  background: #ecfdf7;
  border: 1px solid rgba(24, 169, 153, 0.34);
  border-radius: 8px;
}

.package-grid,
.payment-method-grid {
  display: grid;
  gap: 10px;
}

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

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

.package-card,
.pay-method {
  position: relative;
  min-width: 0;
  padding: 14px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
}

.package-card.active,
.pay-method.active {
  background: #eefaf7;
  border-color: rgba(24, 169, 153, 0.54);
  box-shadow: 0 12px 26px rgba(24, 169, 153, 0.12);
}

.package-card input,
.pay-method input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.package-card strong,
.package-card span,
.package-card b,
.package-card small,
.package-card i,
.pay-method strong,
.pay-method small {
  display: block;
}

.package-card i {
  width: fit-content;
  margin-bottom: 6px;
  padding: 3px 8px;
  color: #334155;
  font-style: normal;
  font-size: 11px;
  font-weight: 800;
  background: #e2e8f0;
  border-radius: 999px;
}

.package-card em {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 4px 8px;
  color: #064e3b;
  font-style: normal;
  font-size: 12px;
  font-weight: 800;
  background: #bff7e9;
  border-radius: 999px;
}

.package-card strong {
  color: var(--ink);
}

.package-card span,
.package-card small,
.pay-method small {
  color: var(--muted);
  font-size: 12px;
}

.package-card b {
  margin-top: 8px;
  color: var(--blue);
  font-size: 24px;
}

.pay-method {
  display: grid;
  grid-template-columns: 42px 1fr;
  column-gap: 10px;
  align-items: center;
}

.pay-method span {
  display: grid;
  grid-row: span 2;
  place-items: center;
  width: 42px;
  height: 42px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  border-radius: 8px;
}

.payment-preview-card {
  display: grid;
  grid-template-columns: 116px 1fr;
  gap: 14px;
  align-items: center;
  padding: 14px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.payment-preview-card h3 {
  margin: 0 0 6px;
  color: var(--ink);
  font-size: 18px;
}

.payment-preview-card p {
  margin: 0 0 6px;
}

.payment-preview-card small {
  color: #d84d35;
}

.qr-mock {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
  width: 104px;
  height: 104px;
  padding: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.qr-mock span {
  background: #18212f;
  border-radius: 2px;
}

.qr-mock span:nth-child(2),
.qr-mock span:nth-child(3) {
  opacity: 0.55;
}

.qr-mock strong {
  position: absolute;
  inset: 36px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--teal);
  border-radius: 8px;
}

.recharge-note {
  min-width: 220px;
  max-width: 340px;
  color: #475569;
  line-height: 1.6;
}

.api-panel {
  display: grid;
  gap: 14px;
}

.api-panel label span {
  display: block;
  margin-bottom: 6px;
  color: #334155;
  font-size: 13px;
  font-weight: 700;
}

.api-panel pre {
  margin: 0;
  padding: 16px;
  color: #dbeafe;
  overflow: auto;
  background: #121826;
  border-radius: 8px;
}

.api-panel code {
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 12px;
  line-height: 1.7;
}

.link-btn {
  width: max-content;
  padding: 0;
  color: var(--blue);
  background: transparent;
}

.account-panel,
.admin-panel {
  display: grid;
  gap: 14px;
}

.account-hero {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 14px;
  color: #fff;
  background: linear-gradient(135deg, #172033, #243b53);
  border-radius: 8px;
}

.account-hero strong,
.account-hero span {
  display: block;
}

.account-hero strong {
  font-size: 20px;
}

.account-hero span {
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.72);
}

.account-sync-banner {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.account-sync-banner strong,
.account-sync-banner span {
  display: block;
  min-width: 0;
}

.account-sync-banner strong {
  color: #101318;
  font-size: 13px;
  font-weight: 900;
}

.account-sync-banner span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.account-avatar-large {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  font-size: 28px;
  font-weight: 900;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.profile-name-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 112px;
  gap: 10px;
  align-items: end;
  padding: 12px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.profile-settings-form {
  grid-template-columns: 1fr;
  align-items: stretch;
}

.avatar-picker {
  min-width: 0;
  padding: 0;
  border: 0;
}

.avatar-picker legend {
  margin-bottom: 8px;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
}

.avatar-picker > div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.avatar-swatch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.avatar-swatch span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: #fff;
  font-weight: 900;
  border: 2px solid transparent;
  border-radius: 50%;
}

.avatar-swatch input:checked + span {
  border-color: #0f172a;
  box-shadow: 0 0 0 3px rgba(44, 123, 229, 0.16);
}

.account-status-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.account-status-grid div {
  padding: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.account-status-grid span,
.account-status-grid strong {
  display: block;
}

.account-status-grid span {
  color: var(--muted);
  font-size: 12px;
}

.account-status-grid strong {
  margin-top: 6px;
  overflow-wrap: anywhere;
}

.profile-name-form .soft-btn {
  height: 40px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.metric-card {
  padding: 14px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.metric-card span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.metric-card strong {
  display: block;
  margin-top: 8px;
  font-size: 22px;
}

.action-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.action-row.compact {
  flex-wrap: wrap;
}

.data-table {
  max-height: 280px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.data-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.data-table th,
.data-table td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.data-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: #475569;
  background: #f8fafc;
}

.positive {
  color: #0f8a70;
  font-weight: 700;
}

.negative {
  color: #d84d35;
  font-weight: 700;
}

.mini-btn {
  height: 30px;
  margin-right: 6px;
  padding: 0 10px;
  color: #fff;
  background: var(--teal);
  border-radius: 8px;
}

.mini-btn.danger {
  background: var(--coral);
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 40;
  padding: 12px 16px;
  color: #fff;
  background: rgba(24, 33, 47, 0.92);
  border-radius: 8px;
  transform: translateX(-50%);
}

.app-loading-tip {
  position: fixed;
  right: 22px;
  bottom: 24px;
  z-index: 39;
  max-width: min(320px, calc(100vw - 44px));
  padding: 12px 14px;
  color: #0f6b61;
  font-size: 13px;
  font-weight: 800;
  background: rgba(238, 250, 247, 0.96);
  border: 1px solid rgba(24, 169, 153, 0.24);
  border-radius: 8px;
  box-shadow: 0 16px 36px rgba(35, 55, 90, 0.14);
}

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

.workspace[data-left-open="false"] {
  grid-template-columns: 76px minmax(520px, 1fr) 420px;
}

.workspace[data-left-open="false"] .task-pane > *:not(.pane-head) {
  display: none;
}

.workspace[data-left-open="false"] .pane-head {
  flex-direction: column;
}

.workspace[data-left-open="false"] .primary-btn {
  width: 44px;
  padding: 0;
  overflow: hidden;
}

@media (max-width: 1180px) {
  body {
    min-width: 0;
  }

  .landing-nav {
    grid-template-columns: 1fr;
    height: auto;
    padding: 14px 0;
  }

  .landing-nav nav,
  .landing-actions,
  .hero-actions,
  .landing-footer {
    flex-wrap: wrap;
    justify-content: center;
  }

  .landing-brand {
    justify-content: center;
  }

  .hero-section {
    min-height: auto;
    padding-top: 72px;
  }

  .hero-section h1 {
    font-size: 48px;
  }

  .preview-board,
  .step-grid,
  .ability-grid,
  .solution-grid,
  .pay-grid,
  .pricing-grid,
  .case-grid,
  .package-grid,
  .payment-method-grid,
  .payment-preview-card,
  .account-status-grid,
  .code-row {
    grid-template-columns: 1fr;
  }

  .pricing-grid article.popular {
    transform: none;
  }

  .landing-footer {
    text-align: center;
  }

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

  .task-pane,
  .builder-pane,
  .preview-pane {
    min-height: 420px;
  }

  .assistant-card {
    grid-template-columns: 44px minmax(0, 1fr);
  }

  .topbar {
    height: auto;
    align-items: flex-start;
    gap: 16px;
    padding: 16px;
  }

  .top-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }
}

@media (max-width: 640px) {
  .builder-pane {
    padding: 14px;
  }

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

  .design-form select,
  .design-form input,
  .design-form textarea {
    min-width: 0;
    width: 100%;
  }
}

/* 方案A工作台：黑白灰、高留白、左历史 + 中画布 + 右设置，弱化营销感。 */
#app {
  --ink: #151a21;
  --muted: #77818d;
  --line: #e1e7eb;
  --panel: #ffffff;
  --soft: #f5f7f8;
  --blue: #151a21;
  --teal: #323b48;
  --coral: #d94b40;
  --amber: #b88728;
  --shadow: 0 18px 46px rgba(17, 24, 39, 0.07);
  min-height: 100vh;
  color: var(--ink);
  background: linear-gradient(180deg, #fdfdfd 0%, #f2f4f6 100%);
}

#app .topbar {
  height: 62px;
  margin: 14px 18px 0;
  padding: 0 16px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow);
}

#app .brand {
  gap: 10px;
  min-width: 260px;
}

#app .brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 14px;
  background: linear-gradient(135deg, #151a21, #323b48);
  box-shadow: 0 10px 22px rgba(17, 24, 39, 0.13);
}

#app .brand h1 {
  font-size: 17px;
  line-height: 1.2;
}

#app .brand p {
  margin-top: 2px;
  color: #7b858f;
  font-size: 12px;
}

/* 关键清理：方案A只保留必要账户动作，后台入口仍由管理员登录态控制显示。 */
#app .top-actions {
  gap: 8px;
}

#app .top-actions .soft-btn[data-action="open-invite"],
#app .top-actions .soft-btn[data-action="open-help"],
#app .top-actions .soft-btn[data-action="open-contact"] {
  display: none;
}

#app .feedback-chip {
  min-width: 80px;
  background: #f7f8f9;
}

#app .soft-btn,
#app .icon-btn,
#app .avatar-btn {
  height: 34px;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid var(--line);
}

#app .soft-btn {
  padding: 0 12px;
  color: #343c47;
  font-size: 13px;
  font-weight: 720;
}

#app .account-chip {
  min-width: 108px;
  color: #151a21;
  background: #f4f6f7;
}

#app .recharge-chip,
#app .top-actions #authBtn {
  color: #ffffff;
  background: #151a21;
  border-color: #151a21;
}

#app .avatar-btn {
  width: 34px;
  color: #ffffff;
  background: linear-gradient(135deg, #151a21, #323b48);
}

/* 关键布局：用 CSS 网格把真实 DOM 调整为方案A顺序，中间优先展示图片画布。 */
#app .workspace {
  display: grid;
  grid-template-areas: "tasks preview builder";
  grid-template-columns: 236px minmax(520px, 1fr) 430px;
  gap: 16px;
  align-items: stretch;
  min-height: calc(100vh - 94px);
  padding: 16px 18px 18px;
}

#app .task-pane {
  grid-area: tasks;
}

#app .preview-pane {
  grid-area: preview;
}

#app .builder-pane {
  grid-area: builder;
}

#app .task-pane,
#app .builder-pane,
#app .preview-pane {
  min-height: calc(100vh - 112px);
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

#app .task-pane {
  padding: 16px;
}

#app .pane-head {
  gap: 8px;
}

#app .pane-head .primary-btn {
  height: 36px;
  border-radius: 14px;
  font-size: 13px;
}

#app .pane-head .icon-btn {
  width: 36px;
}

#app .task-list {
  max-height: calc(100vh - 250px);
  padding: 14px 0 10px;
}

#app .task-card {
  grid-template-columns: 42px minmax(0, 1fr) 24px;
  gap: 10px;
  margin-bottom: 10px;
  padding: 10px;
  border-color: #e5eaed;
  border-radius: 16px;
  box-shadow: none;
}

#app .task-card.active {
  background: #f3f5f7;
  border-color: #dce3e8;
  box-shadow: inset 0 0 0 1px rgba(17, 24, 39, 0.03);
}

#app .thumb {
  width: 42px;
  height: 42px;
  color: #151a21;
  background: #eef1f3;
  border-color: #dde5e8;
  border-radius: 14px;
}

#app .task-card strong {
  margin-bottom: 2px;
  overflow: hidden;
  color: #151a21;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#app .task-card p {
  font-size: 12px;
}

#app .task-badge {
  height: 20px;
  color: #59636f;
  background: #f3f5f7;
  border: 1px solid #e3e9ec;
}

#app .fav-btn {
  color: #a1abb5;
  font-size: 16px;
}

#app .task-filter {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

#app .task-filter input,
#app .task-filter select {
  height: 36px;
  border-radius: 12px;
  background: #f9fafb;
}

#app .check-line {
  width: max-content;
  white-space: nowrap;
}

#app .check-line input {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
}

#app .check-line span {
  white-space: nowrap;
}

#app .preview-pane {
  padding: 18px;
}

#app .result-stage {
  display: grid;
  width: 100%;
  height: 100%;
  min-height: calc(100vh - 150px);
  padding: 18px;
  overflow: auto;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 22px;
}

#app .result-stage:empty {
  place-items: start center;
  padding-top: 24px;
  background:
    linear-gradient(180deg, rgba(245, 247, 248, 0.78), rgba(255, 255, 255, 0.96)),
    #ffffff;
}

/* 关键占位：空结果区只呈现画布骨架，不堆说明文字，避免干扰生成后图片展示。 */
#app .result-stage:empty::before {
  display: block;
  width: min(430px, 68%);
  height: calc(100% - 48px);
  min-height: 420px;
  max-height: 690px;
  content: "";
  background:
    linear-gradient(90deg, transparent 0 7%, #151a21 7% 72%, transparent 72% 100%) 50% 23% / 72% 14px no-repeat,
    linear-gradient(90deg, transparent 0 18%, #d8e1e5 18% 62%, transparent 62% 100%) 50% 29% / 72% 9px no-repeat,
    linear-gradient(135deg, #f2ece3, #fbf8f2) 50% 6% / 76% 19% no-repeat,
    linear-gradient(135deg, #8f6747, #513527 58%, #21150f) 50% 16% / 42% 8% no-repeat,
    linear-gradient(135deg, #ffffff, #f7f8f9) 22% 45% / 35% 16% no-repeat,
    linear-gradient(135deg, #d7ba95, #b88f68) 78% 45% / 35% 16% no-repeat,
    linear-gradient(135deg, #d7ba95, #b88f68) 22% 66% / 35% 16% no-repeat,
    linear-gradient(135deg, #ffffff, #f7f8f9) 78% 66% / 35% 16% no-repeat,
    #f5f7f8;
  border: 1px solid #dce4e8;
  border-radius: 24px;
  box-shadow: 0 16px 34px rgba(17, 24, 39, 0.06);
}

#app .result-stage.has-result {
  display: block;
  background: #ffffff;
  border-color: var(--line);
}

#app .result-image-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

#app .generated-image {
  width: 100%;
  max-height: calc(100vh - 178px);
  object-fit: contain;
  background: #f5f7f8;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 12px 28px rgba(17, 24, 39, 0.08);
}

#app .builder-pane {
  padding: 12px 14px;
  overflow: auto;
}

#app .assistant-card {
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 9px;
  padding: 0 0 10px;
  margin: 0;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  box-shadow: none;
}

#app .assistant-avatar {
  width: 34px;
  height: 34px;
  background: linear-gradient(135deg, #151a21, #323b48);
  border-radius: 14px;
  box-shadow: none;
}

#app .assistant-card p {
  color: #6d7782;
  font-size: 12px;
  line-height: 1.45;
}

#app .assistant-card span {
  display: block;
  color: #151a21;
  font-size: 16px;
  font-weight: 800;
}

#app .design-form {
  padding: 4px 0 0;
}

#app .design-form label,
#app .upload-field {
  padding: 4px 0;
  border-bottom: 1px solid #edf1f3;
}

#app .design-form span,
#app .upload-field > span {
  margin-bottom: 5px;
  color: #626c78;
  font-size: 12px;
  font-weight: 800;
}

#app .design-form input,
#app .design-form select,
#app .design-form textarea {
  color: #151a21;
  background: #ffffff;
  border-color: #dde5e8;
  border-radius: 14px;
}

#app .design-form input,
#app .design-form select {
  height: 34px;
  padding: 0 10px;
}

#app .design-form textarea {
  min-height: 40px;
  padding: 7px 10px;
  line-height: 1.35;
}

#app .design-form input:focus,
#app .design-form textarea:focus,
#app .design-form select:focus {
  border-color: #151a21;
  box-shadow: 0 0 0 3px rgba(17, 24, 39, 0.08);
}

#app .form-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
}

#app .upload-box {
  min-height: 48px;
  padding: 8px;
  background:
    linear-gradient(#fbfcfc, #fbfcfc) padding-box,
    repeating-linear-gradient(90deg, #cbd5dc 0 10px, transparent 10px 18px) border-box;
  border-radius: 16px;
}

#app .upload-box strong {
  font-size: 12px;
}

#app .upload-box small,
#app .upload-box em,
#app .upload-field p {
  display: none;
}

#app .upload-box small,
#app .upload-box em {
  color: #7b858f;
  font-size: 11px;
  line-height: 1.25;
}

#app .compact .upload-box {
  min-height: 42px;
}

#app .upload-cover {
  background: #ffffff;
  border-color: #cbd5dc;
  border-radius: 16px;
  box-shadow: none;
}

#app .upload-cover::after {
  color: #151a21;
  background: #f3f5f7;
}

#app .form-action {
  gap: 6px;
  margin-top: 8px;
  padding: 8px;
  background: #f7f9fa;
  border-color: #e1e7eb;
  border-radius: 18px;
  box-shadow: none;
}

#app .submit-btn,
#app .primary-btn {
  color: #ffffff;
  background: linear-gradient(135deg, #151a21, #323b48);
  border-radius: 14px;
  box-shadow: 0 12px 24px rgba(17, 24, 39, 0.12);
}

#app .submit-btn {
  height: 40px;
  font-size: 14px;
}

#app .form-action small.is-live,
#app .auth-loading-tip,
#app .phone-code-hint,
#app .auth-hint {
  color: #334155;
}

#app .form-action small {
  font-size: 11px;
  line-height: 1.25;
}

#app .app-loading-tip {
  color: #334155;
  background: rgba(255, 255, 255, 0.96);
  border-color: var(--line);
}

#app .popover,
#app .modal {
  border-radius: 18px;
}

@media (max-width: 1240px) {
  #app .topbar {
    margin: 10px 12px 0;
  }

  #app .brand {
    min-width: 220px;
  }

  #app .workspace {
    grid-template-columns: 190px minmax(360px, 1fr) 340px;
    gap: 12px;
    padding: 12px;
  }

  #app .task-pane,
  #app .builder-pane,
  #app .preview-pane {
    min-height: calc(100vh - 96px);
    border-radius: 20px;
  }

  #app .task-card {
    grid-template-columns: 36px minmax(0, 1fr) 20px;
    gap: 8px;
  }

  #app .thumb {
    width: 36px;
    height: 36px;
  }

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

@media (max-width: 900px) {
  #app .workspace {
    grid-template-areas:
      "tasks"
      "preview"
      "builder";
    grid-template-columns: 1fr;
  }

  #app .task-pane,
  #app .builder-pane,
  #app .preview-pane {
    min-height: 420px;
  }

  #app .result-stage {
    min-height: 520px;
  }
}

@media (max-width: 760px) {
  #app .topbar {
    height: auto;
    align-items: flex-start;
    gap: 12px;
    padding: 12px;
  }

  #app .brand {
    min-width: 0;
  }

  #app .top-actions {
    justify-content: flex-start;
  }

  #app .form-grid {
    grid-template-columns: 1fr;
  }
}

/* 截图版工作台：严格对齐用户给出的左导航 + 表单 + 预览图网格布局。 */
#app.ai-layout {
  --sidebar-width: 166px;
  display: grid;
  grid-template-areas: "sidebar main";
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  min-height: 100vh;
  color: #202124;
  background:
    linear-gradient(90deg, rgba(248, 248, 248, 0.96) 0 var(--sidebar-width), #ffffff var(--sidebar-width)),
    #ffffff;
  transition: grid-template-columns 180ms ease;
}

#app.ai-layout.is-sidebar-collapsed {
  --sidebar-width: 68px;
}

#app.ai-layout .app-sidebar {
  grid-area: sidebar;
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  height: 100vh;
  min-height: 0;
  padding: 18px 10px 14px;
  background: linear-gradient(180deg, #f6f6f6 0%, #f9f9f9 100%);
  border: 0;
  border-right: 1px solid #eeeeee;
  border-radius: 0;
  box-shadow: none;
  transition: padding 180ms ease;
}

#app.ai-layout .sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 15px;
}

#app.ai-layout .sidebar-brand {
  display: flex;
  flex: 1 1 auto;
  gap: 8px;
  align-items: center;
  min-width: 0;
  padding: 0 4px;
  color: #191a1c;
  font-size: 15px;
  font-weight: 850;
  white-space: nowrap;
  cursor: default;
  user-select: none;
}

#app.ai-layout .sidebar-brand strong,
#app.ai-layout .nav-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: opacity 140ms ease, width 180ms ease;
}

#app.ai-layout .brand-spark {
  display: grid;
  place-items: center;
  flex: 0 0 30px;
  position: relative;
  width: 30px;
  height: 30px;
  color: #ffffff;
  font-size: 17px;
  font-weight: 900;
  line-height: 1;
  border-radius: 9px;
  background:
    radial-gradient(circle at 72% 24%, rgba(255, 255, 255, 0.82) 0 2px, transparent 3px),
    linear-gradient(145deg, #1f2025 0%, #0f1013 62%, #32343a 100%);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.16);
}

#app.ai-layout .brand-spark::before,
#app.ai-layout .brand-spark::after {
  position: absolute;
  content: "";
}

#app.ai-layout .brand-spark::before {
  top: 6px;
  right: 7px;
  z-index: 1;
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  transform: none;
}

#app.ai-layout .brand-spark::after {
  right: 6px;
  bottom: 6px;
  z-index: 1;
  width: 9px;
  height: 9px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-left: 0;
  border-top: 0;
  border-radius: 2px 0 3px;
  background: transparent;
  transform: none;
}

#app.ai-layout .sidebar-collapse-btn {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  width: 30px;
  height: 28px;
  color: #2a2b2e;
  font-size: 22px;
  font-weight: 750;
  line-height: 1;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid #dddddd;
  border-radius: 8px;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
}

#app.ai-layout .sidebar-collapse-btn:hover {
  background: #ffffff;
  border-color: #cfcfcf;
}

#app.ai-layout .sidebar-collapse-btn:focus-visible,
#app.ai-layout .nav-item:focus-visible,
#app.ai-layout .footer-link:focus-visible {
  outline: 2px solid #202124;
  outline-offset: 2px;
}

#app.ai-layout .sidebar-collapse-btn span {
  display: block;
  width: 1em;
  height: 1em;
  line-height: 0.86;
  transform: translateX(-1px);
}

#app.ai-layout .sidebar-nav {
  display: grid;
  gap: 7px;
}

#app.ai-layout .nav-item,
#app.ai-layout .footer-link {
  display: flex;
  gap: 8px;
  align-items: center;
  width: 100%;
  height: 38px;
  min-width: 0;
  padding: 0 10px;
  color: #3b3d40;
  font-size: 13px;
  font-weight: 650;
  text-align: left;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 7px;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

#app.ai-layout .nav-item.active {
  color: #1f2022;
  background: #ededed;
  border-color: #ededed;
}

#app.ai-layout .home-nav-item {
  color: #303236;
  background: #ffffff;
  border: 1px solid #e1e1e1;
}

#app.ai-layout .nav-icon {
  display: inline-grid;
  flex: 0 0 20px;
  place-items: center;
  position: relative;
  width: 20px;
  height: 20px;
  color: #222326;
  font-size: 0;
  font-weight: 800;
  background: #f5f5f5;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
}

#app.ai-layout .nav-icon::before,
#app.ai-layout .nav-icon::after {
  position: absolute;
  content: "";
}

#app.ai-layout .icon-home::before {
  top: 6px;
  width: 9px;
  height: 9px;
  border: 1.8px solid currentColor;
  border-top: 0;
  border-radius: 1px 1px 2px 2px;
}

#app.ai-layout .icon-home::after {
  top: 4px;
  width: 8px;
  height: 8px;
  border-top: 1.8px solid currentColor;
  border-left: 1.8px solid currentColor;
  transform: rotate(45deg);
}

#app.ai-layout .icon-image::before {
  width: 11px;
  height: 9px;
  border: 1.8px solid currentColor;
  border-radius: 2px;
}

#app.ai-layout .icon-image::after {
  right: 4px;
  bottom: 5px;
  width: 7px;
  height: 5px;
  background: currentColor;
  clip-path: polygon(0 100%, 42% 35%, 62% 62%, 78% 40%, 100% 100%);
}

#app.ai-layout .icon-video::before {
  width: 0;
  height: 0;
  margin-left: 2px;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  border-left: 8px solid currentColor;
}

#app.ai-layout .icon-history::before {
  width: 11px;
  height: 11px;
  border: 1.8px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  transform: rotate(-18deg);
}

#app.ai-layout .icon-history::after {
  left: 4px;
  top: 4px;
  width: 5px;
  height: 5px;
  border-left: 1.8px solid currentColor;
  border-bottom: 1.8px solid currentColor;
  transform: rotate(24deg);
}

#app.ai-layout .icon-queue::before {
  width: 11px;
  height: 8px;
  border-top: 1.8px solid currentColor;
  border-bottom: 1.8px solid currentColor;
}

#app.ai-layout .icon-queue::after {
  width: 11px;
  height: 1.8px;
  background: currentColor;
  border-radius: 99px;
}

#app.ai-layout .icon-cases::before {
  width: 11px;
  height: 11px;
  border: 1.7px solid currentColor;
  border-radius: 2px;
  box-shadow: inset 0 -4px 0 rgba(32, 33, 36, 0.14);
}

#app.ai-layout .icon-cases::after {
  top: 5px;
  width: 11px;
  height: 1.7px;
  background: currentColor;
}

#app.ai-layout .icon-settings::before {
  width: 11px;
  height: 11px;
  border: 1.8px solid currentColor;
  border-radius: 50%;
  box-shadow:
    0 -4px 0 -2.3px currentColor,
    0 4px 0 -2.3px currentColor,
    4px 0 0 -2.3px currentColor,
    -4px 0 0 -2.3px currentColor;
}

#app.ai-layout .icon-settings::after {
  width: 3.5px;
  height: 3.5px;
  background: currentColor;
  border-radius: 50%;
}

#app.ai-layout .icon-help::before {
  content: "?";
  position: static;
  color: currentColor;
  font-size: 13px;
  font-weight: 850;
  line-height: 1;
}

#app.ai-layout .nav-label {
  min-width: 0;
}

#app.ai-layout .task-tools {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  min-height: 0;
}

#app.ai-layout .task-list {
  display: none;
}

#app.ai-layout .task-tools input,
#app.ai-layout .task-tools select {
  display: none;
}

#app.ai-layout .task-tools .check-line {
  display: none;
}

#app.ai-layout .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

#app.ai-layout .plan-card {
  display: grid;
  gap: 6px;
  justify-items: center;
  padding: 12px;
  margin-top: auto;
  text-align: center;
  background: #ffffff;
  border: 1px solid #e3e3e3;
  border-radius: 6px;
}

#app.ai-layout .plan-card strong {
  font-size: 13px;
  line-height: 1.3;
}

#app.ai-layout .plan-card span {
  color: #777b80;
  font-size: 11px;
  white-space: nowrap;
}

#app.ai-layout .plan-card button {
  height: 30px;
  width: 100%;
  margin-top: 6px;
  color: #202124;
  font-size: 13px;
  font-weight: 650;
  background: #ffffff;
  border: 1px solid #dddddd;
  border-radius: 4px;
}

#app.ai-layout .sidebar-footer {
  display: grid;
  gap: 4px;
  margin-top: 12px;
}

#app.ai-layout .footer-link {
  height: 36px;
  padding: 0 10px;
  font-size: 13px;
  font-weight: 500;
}

#app.ai-layout.is-sidebar-collapsed .app-sidebar {
  align-items: center;
  padding-right: 8px;
  padding-left: 8px;
}

#app.ai-layout.is-sidebar-collapsed .sidebar-head {
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  width: 100%;
}

#app.ai-layout.is-sidebar-collapsed .sidebar-brand {
  justify-content: center;
  gap: 0;
  padding: 0;
}

#app.ai-layout.is-sidebar-collapsed .sidebar-brand strong,
#app.ai-layout.is-sidebar-collapsed .nav-label {
  width: 0;
  opacity: 0;
  pointer-events: none;
}

#app.ai-layout.is-sidebar-collapsed .sidebar-collapse-btn span {
  transform: translateX(1px);
}

#app.ai-layout.is-sidebar-collapsed .sidebar-nav,
#app.ai-layout.is-sidebar-collapsed .sidebar-footer {
  width: 100%;
}

#app.ai-layout.is-sidebar-collapsed .nav-item,
#app.ai-layout.is-sidebar-collapsed .footer-link {
  justify-content: center;
  gap: 0;
  padding: 0;
}

#app.ai-layout.is-sidebar-collapsed .plan-card {
  display: none;
}

#app.ai-layout.is-sidebar-collapsed .sidebar-footer {
  margin-top: auto;
}

#app.ai-layout .commerce-main {
  grid-area: main;
  min-width: 0;
  padding: 12px 24px 22px;
}

#app.ai-layout .commerce-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-width: 0;
  margin-bottom: 12px;
}

#app.ai-layout .commerce-header > div {
  flex: 1 1 320px;
  min-width: 260px;
}

#app.ai-layout .commerce-header h1 {
  margin: 0;
  color: #161719;
  font-size: 22px;
  line-height: 1.2;
  font-weight: 850;
  white-space: nowrap;
}

#app.ai-layout .commerce-header p {
  max-width: 460px;
  margin: 3px 0 0;
  overflow: hidden;
  color: #757a80;
  font-size: 13px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#app.ai-layout .top-actions {
  display: flex;
  flex: 0 1 auto;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
  max-width: min(640px, 58vw);
  row-gap: 6px;
}

#app.ai-layout .credit-display {
  display: inline-flex;
  gap: 7px;
  align-items: center;
  justify-content: center;
  width: 96px;
  max-width: 96px;
  height: 34px;
  padding: 0 12px;
  box-sizing: border-box;
  color: #2f3135;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  background: #ffffff;
  border: 1px solid #dfdfdf;
  border-radius: 7px;
}

#app.ai-layout .credit-display span {
  color: #5f6368;
  font-size: 13px;
  font-weight: 520;
  line-height: 1;
}

#app.ai-layout .credit-display strong {
  display: inline-block;
  max-width: 6ch;
  overflow: hidden;
  color: #202124;
  font-size: 14px;
  font-weight: 760;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
  line-height: 1;
  text-overflow: clip;
}

#app.ai-layout .recharge-chip,
#app.ai-layout .top-home-btn,
#app.ai-layout .ops-top-entry,
#app.ai-layout #authBtn,
#app.ai-layout .gift-btn,
#app.ai-layout .avatar-btn {
  height: 34px;
  border-radius: 7px;
}

#app.ai-layout .recharge-chip,
#app.ai-layout .top-home-btn,
#app.ai-layout .ops-top-entry,
#app.ai-layout #authBtn {
  padding: 0 14px;
  color: #202124;
  font-size: 13px;
  font-weight: 650;
  white-space: nowrap;
  background: #ffffff;
  border: 1px solid #dfdfdf;
}

#app.ai-layout .ops-top-entry {
  display: none;
}

#app.ai-layout .gift-btn {
  width: 34px;
  color: #222326;
  background: #ffffff;
  border: 1px solid #dfdfdf;
}

#app.ai-layout .gift-icon {
  position: relative;
  display: block;
  width: 17px;
  height: 15px;
  box-sizing: border-box;
  color: currentColor;
  border: 1.8px solid currentColor;
  border-radius: 3px;
  background:
    linear-gradient(90deg, transparent calc(50% - 0.9px), currentColor calc(50% - 0.9px) calc(50% + 0.9px), transparent calc(50% + 0.9px)),
    linear-gradient(180deg, transparent 4.5px, currentColor 4.5px 6.3px, transparent 6.3px);
}

#app.ai-layout .gift-icon::before {
  position: absolute;
  top: -7px;
  left: 50%;
  width: 15px;
  height: 8px;
  box-sizing: border-box;
  content: "";
  border: 1.8px solid currentColor;
  border-bottom: 0;
  border-radius: 9px 9px 2px 2px;
  transform: translateX(-50%);
  background: linear-gradient(90deg, transparent calc(50% - 0.9px), currentColor calc(50% - 0.9px) calc(50% + 0.9px), transparent calc(50% + 0.9px));
}

#app.ai-layout .avatar-btn {
  width: 34px;
  color: #ffffff;
  font-size: 15px;
  font-weight: 700;
  background: #3f4145;
  border: 0;
}

#app.ai-layout .workspace {
  display: grid;
  grid-template-areas: "builder preview";
  grid-template-columns: minmax(560px, 1fr) minmax(500px, 0.96fr);
  gap: 18px;
  min-height: 0;
  padding: 0;
}

#app.ai-layout .builder-pane,
#app.ai-layout .preview-pane {
  min-height: calc(100vh - 96px);
  background: #ffffff;
  border: 1px solid #dedede;
  border-radius: 6px;
  box-shadow: none;
}

#app.ai-layout .generation-card {
  grid-area: builder;
  padding: 28px;
  overflow: auto;
}

#app.ai-layout .design-form {
  display: grid;
  gap: 22px;
  padding: 0;
  letter-spacing: 0;
}

#app.ai-layout .design-form label,
#app.ai-layout .upload-field,
#app.ai-layout .segmented-field {
  position: relative;
  display: grid;
  gap: 10px;
  padding: 0;
  margin: 0;
  border: 0;
}

#app.ai-layout .field-title {
  display: block;
  width: 100%;
  padding: 0;
  margin: 0;
}

#app.ai-layout .main-image-page {
  display: grid;
  gap: 12px;
  padding: 18px;
  background: linear-gradient(180deg, #fbfbfb 0%, #ffffff 100%);
  border: 1px solid #dedede;
  border-radius: 6px;
}

#app.ai-layout .main-image-page.is-missing {
  border-color: #d61f1f;
  box-shadow: 0 0 0 2px rgba(214, 31, 31, 0.08);
}

#app.ai-layout .main-image-page.has-main-image {
  border-color: #b8b8b8;
  background: #ffffff;
}

#app.ai-layout .section-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

#app.ai-layout .section-title small {
  color: #777b80;
  font-size: 12px;
  line-height: 1.45;
  text-align: right;
}

#app.ai-layout .product-meta-grid {
  align-items: start;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

#app.ai-layout .generation-mode-field {
  min-width: 0;
}

#app.ai-layout .custom-category-field {
  grid-column: 1 / -1;
  min-width: 0;
}

#app.ai-layout .main-image-upload {
  gap: 8px;
}

#app.ai-layout .main-image-upload .upload-box {
  min-height: 96px;
}

#app.ai-layout .main-image-upload p {
  margin: 0;
  color: #85888d;
  font-size: 12px;
  line-height: 1.45;
}

#app.ai-layout .design-form span,
#app.ai-layout .upload-field > span,
#app.ai-layout .segmented-field legend,
#app.ai-layout .section-title span {
  color: #232426;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.35;
  letter-spacing: 0;
  white-space: nowrap;
}

#app.ai-layout .design-form b,
#app.ai-layout .upload-field b,
#app.ai-layout .segmented-field b {
  color: #d61f1f;
}

#app.ai-layout .design-form input,
#app.ai-layout .design-form textarea,
#app.ai-layout .design-form select {
  width: 100%;
  color: #33363a;
  font-size: 14px;
  letter-spacing: 0;
  background: #ffffff;
  border: 1px solid #dedede;
  border-radius: 5px;
  outline: none;
}

#app.ai-layout .design-form input,
#app.ai-layout .design-form select {
  height: 48px;
  padding: 0 16px;
}

#app.ai-layout .design-form textarea {
  min-height: 142px;
  padding: 15px 16px;
  font-size: 14px;
  line-height: 1.65;
  resize: vertical;
}

#app.ai-layout .design-form input:focus,
#app.ai-layout .design-form textarea:focus,
#app.ai-layout .design-form select:focus {
  border-color: #222326;
  box-shadow: 0 0 0 2px rgba(32, 33, 36, 0.08);
}

#app.ai-layout .char-count {
  position: absolute;
  right: 14px;
  bottom: 12px;
  color: #8a8d91;
  font-size: 13px;
  font-style: normal;
}

#app.ai-layout .batch-queue-panel {
  display: grid;
  gap: 12px;
  padding: 16px;
  background: #fbfbfb;
  border: 1px solid #dedede;
  border-radius: 6px;
}

#app.ai-layout .batch-queue-head,
#app.ai-layout .batch-queue-actions,
#app.ai-layout .batch-queue-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

#app.ai-layout .batch-queue-head > div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

#app.ai-layout .batch-queue-head span {
  color: #232426;
  font-size: 14px;
  font-weight: 750;
}

#app.ai-layout .batch-queue-head strong,
#app.ai-layout .batch-queue-panel small,
#app.ai-layout .batch-empty {
  margin: 0;
  color: #777b82;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.55;
}

#app.ai-layout .batch-queue-list {
  display: grid;
  gap: 8px;
}

#app.ai-layout .batch-queue-item {
  min-height: 44px;
  padding: 10px 12px;
  background: #ffffff;
  border: 1px solid #e6e6e6;
  border-radius: 6px;
  cursor: pointer;
}

#app.ai-layout .batch-queue-item:hover,
#app.ai-layout .batch-queue-item:focus-visible {
  border-color: #202124;
  outline: none;
}

#app.ai-layout .batch-queue-item div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

#app.ai-layout .batch-queue-item strong,
#app.ai-layout .batch-queue-item span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  overflow: hidden;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#app.ai-layout .batch-queue-item strong {
  color: #202124;
  font-size: 13px;
}

#app.ai-layout .batch-queue-item span {
  color: #777b82;
  font-size: 12px;
}

#app.ai-layout .batch-queue-item em {
  flex: 0 0 auto;
  padding: 4px 8px;
  color: #ffffff;
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  background: #242529;
  border-radius: 999px;
}

#app.ai-layout .queue-type-pill {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 20px;
  padding: 0 8px;
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  background: #242529;
  border-radius: 999px;
}

#app.ai-layout .queue-type-pill.is-video {
  color: #1d1f23;
  background: #f0d7a6;
}

#app.ai-layout .batch-queue-actions {
  justify-content: flex-start;
}

#app.ai-layout .batch-new-task-btn,
#app.ai-layout .batch-start-btn,
#app.ai-layout .batch-clear-btn {
  min-width: 118px;
  height: 36px;
  padding: 0 14px;
  border-radius: 5px;
}

#app.ai-layout .template-picker,
#app.ai-layout .floor-planner {
  display: grid;
  gap: 14px;
  padding: 18px;
  background: #ffffff;
  border: 1px solid #dedede;
  border-radius: 6px;
}

#app.ai-layout .template-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

#app.ai-layout .template-card {
  display: grid;
  gap: 5px;
  place-items: center;
  min-width: 0;
  min-height: 68px;
  padding: 12px 10px;
  color: #303236;
  text-align: center;
  letter-spacing: 0;
  background: #ffffff;
  border: 1px solid #dddddd;
  border-radius: 6px;
  outline: none;
}

#app.ai-layout .template-card strong {
  width: 100%;
  min-width: 0;
  overflow: hidden;
  color: #202124;
  font-size: 14px;
  line-height: 1.25;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#app.ai-layout .template-card span {
  width: 100%;
  min-width: 0;
  overflow: hidden;
  color: #80848a;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.3;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#app.ai-layout .template-card.is-active {
  color: #ffffff;
  background: #202124;
  border-color: #202124;
  box-shadow: none;
}

#app.ai-layout .template-card.is-active strong,
#app.ai-layout .template-card.is-active span {
  color: #ffffff;
}

#app.ai-layout .locked-floor {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 44px;
  gap: 10px;
  align-items: center;
  min-height: 46px;
  padding: 0 12px;
  background: #f7f7f7;
  border: 1px solid #e4e4e4;
  border-radius: 6px;
}

#app.ai-layout .locked-floor span,
#app.ai-layout .locked-floor em {
  display: inline-grid;
  place-items: center;
  height: 24px;
  color: #6f747b;
  font-size: 12px;
  font-style: normal;
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 999px;
}

#app.ai-layout .locked-floor strong {
  min-width: 0;
  color: #222326;
  font-size: 14px;
  line-height: 1.35;
}

#app.ai-layout .floor-chip-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
}

#app.ai-layout .floor-chip {
  display: inline-flex;
  gap: 5px;
  align-items: center;
  justify-content: center;
  height: 38px;
  min-width: 0;
  padding: 0 8px;
  color: #45484d;
  font-size: 13px;
  line-height: 1.2;
  letter-spacing: 0;
  white-space: nowrap;
  background: #ffffff;
  border: 1px solid #dddddd;
  border-radius: 6px;
}

#app.ai-layout .floor-chip span {
  min-width: 0;
  color: inherit;
  overflow: hidden;
  text-overflow: ellipsis;
}

#app.ai-layout .floor-chip em {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  min-width: 22px;
  height: 20px;
  padding: 0 5px;
  color: #ffffff;
  font-size: 11px;
  font-style: normal;
  line-height: 1;
  background: #202124;
  border: 1px solid rgb(255 255 255 / 0.28);
  border-radius: 999px;
}

#app.ai-layout .floor-chip.is-active {
  color: #ffffff;
  background: #24262a;
  border-color: #24262a;
}

#app.ai-layout .style-tabs {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

#app.ai-layout .style-tabs button {
  height: 44px;
  min-width: 0;
  padding: 0 10px;
  color: #3a3d42;
  font-size: 14px;
  line-height: 1.15;
  letter-spacing: 0;
  background: #ffffff;
  border: 1px solid #dddddd;
  border-radius: 5px;
}

#app.ai-layout .style-tabs button.active {
  color: #ffffff;
  background: #202124;
  border-color: #202124;
  box-shadow: none;
}

#app.ai-layout .form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

/* 关键布局：水印与参考图保持同级卡片，避免一侧撑高后高级设置出现断层空白。 */
#app.ai-layout .watermark-reference-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.94fr);
  gap: 16px;
  align-items: start;
}

#app.ai-layout .watermark-reference-row > .segmented-field,
#app.ai-layout .watermark-reference-row > .upload-field {
  display: grid;
  align-content: start;
  min-width: 0;
  padding: 16px;
  background: #fafafa;
  border: 1px solid #e7e7e7;
  border-radius: 6px;
}

#app.ai-layout .watermark-field {
  width: 100%;
  max-width: 100%;
  gap: 10px;
  align-self: start;
  min-inline-size: 0;
  overflow: hidden;
}

#app.ai-layout .watermark-field * {
  box-sizing: border-box;
  min-width: 0;
}

#app.ai-layout .watermark-field .field-title {
  margin: 0;
  padding: 0;
  line-height: 1.35;
}

#app.ai-layout .watermark-field .compact-tabs {
  width: 100%;
  max-width: 100%;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

#app.ai-layout .watermark-field .style-tabs button {
  width: 100%;
  max-width: 100%;
  height: 44px;
  padding: 0 12px;
  overflow: hidden;
  font-size: 14px;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#app.ai-layout .watermark-field .style-tabs button:focus-visible {
  outline-offset: -3px;
}

#app.ai-layout .watermark-field select {
  display: none;
}

#app.ai-layout .custom-watermark-field {
  width: 100%;
  max-width: 100%;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  margin-top: 0;
  padding: 12px;
  overflow: hidden;
  background: #f4f4f4;
  border: 0;
  border-radius: 5px;
}

#app.ai-layout .watermark-cost-note {
  margin: 2px 0 0;
  color: #85888d;
  font-size: 12px;
  line-height: 1.45;
}

#app.ai-layout .custom-watermark-field span {
  grid-column: auto;
  grid-row: auto;
}

#app.ai-layout .custom-watermark-field input {
  grid-column: auto;
  grid-row: auto;
  width: 100%;
  max-width: 100%;
  height: 38px;
  background: #ffffff;
}

#app.ai-layout .custom-watermark-field small {
  grid-column: auto;
  grid-row: auto;
  color: #85888d;
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

#app.ai-layout .watermark-reference-row > .upload-field {
  gap: 10px;
}

#app.ai-layout .watermark-reference-row > .upload-field .upload-dropzone {
  display: grid;
  min-height: 116px;
}

#app.ai-layout .watermark-reference-row > .upload-field .upload-box {
  min-height: 116px;
}

#app.ai-layout .upload-box {
  display: grid;
  place-items: center;
  min-height: 78px;
  padding: 12px;
  color: #484b50;
  background:
    linear-gradient(#ffffff, #ffffff) padding-box,
    repeating-linear-gradient(90deg, #dadada 0 8px, transparent 8px 14px) border-box;
  border: 1px dashed transparent;
  border-radius: 5px;
}

#app.ai-layout .upload-box strong {
  color: #33363a;
  font-size: 14px;
}

#app.ai-layout .upload-box small {
  display: block;
  color: #8a8d91;
  font-size: 11px;
}

#app.ai-layout .upload-box em {
  display: none;
}

#app.ai-layout .upload-cover {
  border-color: #d7d7d7;
  border-radius: 5px;
}

#app.ai-layout .upload-cover::after {
  color: #33363a;
  background: #f5f5f5;
}

#app.ai-layout .advanced-settings {
  overflow: hidden;
  border: 1px solid #dedede;
  border-radius: 5px;
}

#app.ai-layout .advanced-settings-fixed {
  min-height: 0;
  background: #ffffff;
}

#app.ai-layout .advanced-fixed-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 46px;
  padding: 0 14px;
  color: #2f3135;
  font-size: 14px;
  line-height: 1.35;
  border-bottom: 1px solid #eeeeee;
}

#app.ai-layout .advanced-fixed-label span {
  font-weight: 650;
  white-space: nowrap;
}

#app.ai-layout .advanced-fixed-label small {
  color: #85888d;
  font-size: 12px;
  white-space: nowrap;
}

#app.ai-layout .advanced-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 14px;
  background: #fbfbfb;
}

#app.ai-layout .wide-field {
  grid-column: 1 / -1;
}

#app.ai-layout .advanced-grid textarea {
  min-height: 72px;
}

#app.ai-layout .form-action {
  display: grid;
  gap: 14px;
  padding: 0;
  margin: 0;
  text-align: center;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

#app.ai-layout .submit-btn,
#app.ai-layout .video-submit-btn {
  width: 100%;
  height: 52px;
  color: #ffffff;
  font-size: 16px;
  font-weight: 760;
  background: linear-gradient(180deg, #2f3033 0%, #1e1f21 100%);
  border: 0;
  border-radius: 5px;
  box-shadow: none;
}

#app.ai-layout .form-action small {
  color: #85888d;
  font-size: 14px;
}

#app.ai-layout .preview-pane {
  grid-area: preview;
  padding: 0;
  overflow: hidden;
}

#app.ai-layout .preview-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 28px;
}

#app.ai-layout .preview-headline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

#app.ai-layout .preview-headline strong {
  color: #202124;
  font-size: 15px;
}

#app.ai-layout .preview-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  justify-content: flex-end;
}

#app.ai-layout .preview-actions button {
  color: #5f6368;
  font-size: 14px;
  background: transparent;
  border: 0;
}

#app.ai-layout .preview-actions .preview-task-button {
  min-width: 112px;
  height: 36px;
  padding: 0 14px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 820;
  background: #202124;
  border: 1px solid #202124;
  border-radius: 6px;
  white-space: nowrap;
}

#app.ai-layout .preview-actions .stop-generation-button {
  min-width: 88px;
  height: 36px;
  padding: 0 12px;
  color: #c23b32;
  font-size: 13px;
  font-weight: 820;
  background: #fff4f2;
  border: 1px solid #efb6af;
  border-radius: 6px;
  white-space: nowrap;
}

#app.ai-layout .preview-actions .stop-generation-button:not(:disabled):hover {
  color: #ffffff;
  background: #c23b32;
  border-color: #c23b32;
}

#app.ai-layout .preview-actions .stop-generation-button:disabled {
  color: #b5b5b5;
  cursor: not-allowed;
  background: #f5f5f5;
  border-color: #e2e2e2;
}

#app.ai-layout .preview-actions .download-long-image-button {
  min-width: 56px;
  height: 36px;
  padding: 0 12px;
  color: #24262a;
  font-size: 13px;
  font-weight: 820;
  background: #ffffff;
  border: 1px solid #dedede;
  border-radius: 6px;
  white-space: nowrap;
}

#app.ai-layout .preview-actions .download-long-image-button:not(:disabled):hover {
  color: #ffffff;
  background: #202124;
  border-color: #202124;
}

#app.ai-layout .preview-actions .download-long-image-button:disabled {
  color: #b5b5b5;
  cursor: not-allowed;
  background: #f7f7f7;
}

#app.ai-layout .preview-actions .video-download-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 84px;
  height: 36px;
  padding: 0 14px 0 10px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 840;
  letter-spacing: 0;
  background: linear-gradient(180deg, #2b2d31 0%, #17181a 100%);
  border: 1px solid #17181a;
  border-radius: 999px;
  box-shadow: 0 10px 24px rgba(23, 24, 26, 0.16);
  white-space: nowrap;
}

#app.ai-layout .preview-actions .video-download-button span {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  margin-right: 6px;
  color: #202124;
  font-size: 14px;
  font-weight: 900;
  line-height: 1;
  background: #ffffff;
  border-radius: 50%;
}

#app.ai-layout .preview-actions .video-download-button b {
  font: inherit;
}

#app.ai-layout .preview-actions .video-download-button:not(:disabled):hover {
  background: linear-gradient(180deg, #111214 0%, #000000 100%);
  border-color: #000000;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
  transform: translateY(-1px);
}

#app.ai-layout .preview-actions .video-download-button:not(:disabled):active {
  transform: translateY(0);
}

#app.ai-layout .preview-actions .video-download-button:disabled {
  color: #a8abb0;
  cursor: not-allowed;
  background: #f5f5f5;
  border-color: #e0e0e0;
  box-shadow: none;
}

#app.ai-layout .preview-actions .video-download-button:disabled span {
  color: #a8abb0;
  background: #ffffff;
  border: 1px solid #e5e5e5;
}

#app.ai-layout .preview-actions span {
  width: 1px;
  height: 18px;
  background: #dddddd;
}

#app.ai-layout .result-stage {
  flex: 1;
  min-height: 0;
  padding: 0;
  overflow: auto;
  background: transparent;
  border: 0;
  border-radius: 0;
}

#app.ai-layout .result-stage.has-result {
  background: transparent;
  border: 0;
}

#app.ai-layout .result-stage.is-generating {
  display: grid;
  align-content: start;
  min-height: 560px;
  padding: 14px;
  background: #f8f8f7;
  border: 1px solid #e4e4e4;
  border-radius: 8px;
}

#app.ai-layout .video-workspace {
  grid-template-columns: minmax(560px, 0.92fr) minmax(460px, 0.78fr);
}

#app.ai-layout .video-builder-pane {
  grid-area: builder;
  padding: 26px;
  overflow: auto;
}

#app.ai-layout .video-design-form {
  gap: 18px;
}

#app.ai-layout .video-brief-card,
#app.ai-layout .video-option-card,
#app.ai-layout .video-material-card,
#app.ai-layout .video-storyboard-card {
  display: grid;
  gap: 16px;
  padding: 18px;
  background: #ffffff;
  border: 1px solid #dedede;
  border-radius: 7px;
}

#app.ai-layout .video-brief-card {
  background: linear-gradient(180deg, #fbfbfb 0%, #ffffff 100%);
}

#app.ai-layout .video-meta-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

#app.ai-layout .video-brief-meta-grid {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: end;
  gap: 14px;
}

#app.ai-layout .video-material-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

#app.ai-layout .video-material-grid article {
  display: grid;
  gap: 7px;
  min-height: 118px;
  padding: 14px;
  background: #fafafa;
  border: 1px solid #e8e8e8;
  border-radius: 7px;
}

#app.ai-layout .video-material-grid strong,
#app.ai-layout .video-shot-list strong {
  color: #202124;
  font-size: 14px;
  font-weight: 760;
  line-height: 1.35;
}

#app.ai-layout .video-material-grid p,
#app.ai-layout .video-shot-list em,
#app.ai-layout .video-preview-script p {
  margin: 0;
  color: #757a80;
  font-size: 12px;
  font-style: normal;
  line-height: 1.6;
}

#app.ai-layout .video-shot-list {
  display: grid;
  gap: 10px;
  padding: 0;
  margin: 0;
  list-style: none;
}

#app.ai-layout .video-shot-list li {
  display: grid;
  grid-template-columns: 38px minmax(96px, 0.28fr) minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-height: 46px;
  padding: 10px 12px;
  background: #fbfbfb;
  border: 1px solid #e8e8e8;
  border-radius: 7px;
}

#app.ai-layout .video-shot-list span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
  background: #242529;
  border-radius: 50%;
}

#app.ai-layout .video-submit-row {
  display: grid;
  gap: 10px;
  padding: 18px;
  background: #ffffff;
  border: 1px solid #dedede;
  border-radius: 7px;
}

#app.ai-layout .video-submit-row p {
  margin: 0;
  color: #777b82;
  font-size: 13px;
  line-height: 1.65;
  text-align: center;
}

#app.ai-layout .video-submit-btn {
  background: linear-gradient(180deg, #242529 0%, #17181a 100%);
}

#app.ai-layout .video-preview-pane {
  grid-area: preview;
}

#app.ai-layout .video-preview-card {
  gap: 18px;
  background: #ffffff;
}

#app.ai-layout .video-stage {
  display: grid;
  place-items: center;
  gap: 16px;
  min-height: 520px;
  padding: 28px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.82), rgba(245, 245, 245, 0.72)),
    repeating-linear-gradient(90deg, #f5f5f5 0, #f5f5f5 1px, transparent 1px, transparent 42px);
  border: 1px solid #e4e4e4;
  border-radius: 8px;
}

#app.ai-layout .video-frame-shell {
  display: grid;
  place-items: center;
  width: min(280px, 72%);
  aspect-ratio: 9 / 16;
  padding: 10px;
  background: #202124;
  border-radius: 30px;
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.14);
}

#app.ai-layout .video-phone-frame {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(250, 250, 250, 0.95) 0%, rgba(231, 225, 216, 0.95) 100%),
    radial-gradient(circle at 50% 28%, rgba(120, 82, 54, 0.24), transparent 42%);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 23px;
}

#app.ai-layout .video-phone-frame::before {
  position: absolute;
  top: 22%;
  left: 50%;
  width: 56%;
  height: 28%;
  content: "";
  background: linear-gradient(135deg, #6b4630, #2f1e15);
  border-radius: 10px;
  box-shadow:
    0 20px 34px rgba(39, 24, 15, 0.18),
    inset 0 0 0 2px rgba(255, 255, 255, 0.16);
  transform: translateX(-50%);
}

#app.ai-layout .video-phone-frame::after {
  position: absolute;
  right: 20%;
  bottom: 22%;
  width: 78px;
  height: 78px;
  content: "";
  background: radial-gradient(circle at 50% 42%, #f3efe8 0 26%, #d8c0a8 27% 48%, transparent 49%);
  border-radius: 50%;
  opacity: 0.9;
}

#app.ai-layout .video-scene {
  position: absolute;
  inset: auto 18px 22px;
  z-index: 1;
  display: grid;
  gap: 8px;
  padding: 14px;
  color: #ffffff;
  background: rgba(25, 26, 28, 0.82);
  border-radius: 16px;
  backdrop-filter: blur(12px);
}

#app.ai-layout .video-scene span {
  width: max-content;
  padding: 4px 8px;
  color: #202124;
  font-size: 11px;
  font-weight: 800;
  background: #ffffff;
  border-radius: 999px;
}

#app.ai-layout .video-scene strong {
  font-size: 17px;
  line-height: 1.3;
}

#app.ai-layout .video-scene p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 12px;
  line-height: 1.55;
}

#app.ai-layout .video-timeline {
  width: min(360px, 88%);
  height: 7px;
  overflow: hidden;
  background: #e8e8e8;
  border-radius: 999px;
}

#app.ai-layout .video-timeline i {
  display: block;
  height: 100%;
  background: #242529;
  border-radius: inherit;
}

#app.ai-layout .video-workflow-card,
#app.ai-layout .video-result-card {
  display: grid;
  gap: 14px;
  width: min(420px, 100%);
  padding: 22px;
  background: #ffffff;
  border: 1px solid #e3e3e3;
  border-radius: 8px;
}

#app.ai-layout .video-workflow-card span {
  width: max-content;
  padding: 5px 9px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 820;
  background: #202124;
  border-radius: 999px;
}

#app.ai-layout .video-workflow-card strong,
#app.ai-layout .video-result-card strong {
  color: #202124;
  font-size: 18px;
  line-height: 1.35;
}

#app.ai-layout .video-workflow-card p,
#app.ai-layout .video-result-card p {
  margin: 0;
  color: #6f747b;
  font-size: 13px;
  line-height: 1.7;
}

#app.ai-layout .video-workflow-card.is-error {
  border-color: #f0c6c6;
  background: #fffafa;
}

#app.ai-layout .video-workflow-card.is-error span {
  background: #9f2f2f;
}

#app.ai-layout .video-workflow-bar {
  height: 6px;
  overflow: hidden;
  background: #eeeeee;
  border-radius: 999px;
}

#app.ai-layout .video-workflow-bar i {
  display: block;
  width: 42%;
  height: 100%;
  background: #202124;
  border-radius: inherit;
  animation: videoWorkflowPulse 1.4s ease-in-out infinite alternate;
}

#app.ai-layout .video-result-card video {
  width: 100%;
  max-height: 520px;
  background: #111214;
  border-radius: 8px;
}

#app.ai-layout .video-result-card a {
  color: #202124;
  font-size: 13px;
  font-weight: 760;
}

#app.ai-layout .video-result-card .video-result-download-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: max-content;
  min-height: 36px;
  margin-top: 10px;
  padding: 0 14px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 820;
  text-decoration: none;
  background: #202124;
  border-radius: 999px;
}

#app.ai-layout .video-result-card .video-result-download-link:hover {
  background: #000000;
}

#app.ai-layout .video-segment-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

#app.ai-layout .video-segment-strip button {
  min-height: 34px;
  padding: 0 12px;
  color: #6f747b;
  font: inherit;
  font-size: 12px;
  font-weight: 780;
  background: #f5f5f5;
  border: 1px solid #e2e2e2;
  border-radius: 999px;
  cursor: pointer;
}

#app.ai-layout .video-segment-strip button.is-active {
  color: #ffffff;
  background: #202124;
  border-color: #202124;
}

@keyframes videoWorkflowPulse {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(135%);
  }
}

#app.ai-layout .video-preview-script {
  display: grid;
  gap: 10px;
}

#app.ai-layout .video-preview-script article {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 12px;
  padding: 12px;
  background: #fafafa;
  border: 1px solid #e8e8e8;
  border-radius: 7px;
}

#app.ai-layout .video-preview-script span {
  color: #202124;
  font-size: 12px;
  font-weight: 780;
}

#app.ai-layout .generation-progress-card {
  box-sizing: border-box;
  display: grid;
  gap: 18px;
  width: 100%;
  margin: 0 auto;
  padding: 22px;
  color: #24262a;
  background: #ffffff;
  border: 1px solid #dfdfdf;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 22px 54px rgba(15, 23, 42, 0.08);
}

#app.ai-layout .result-stage.is-generating .generation-progress-card {
  width: 100%;
  margin: 0;
  padding: 22px;
  align-content: start;
}

#app.ai-layout .generation-progress-card.is-summary {
  width: 100%;
  margin-bottom: 14px;
  padding: 12px 14px;
  background: #fbfbfb;
  box-shadow: none;
}

#app.ai-layout .generation-progress-card.is-error {
  border-color: #f0c3c3;
  background: #fffafa;
}

#app.ai-layout .generation-progress-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

#app.ai-layout .generation-summary-line {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

#app.ai-layout .generation-progress-title {
  display: grid;
  gap: 5px;
  min-width: 0;
}

#app.ai-layout .generation-progress-head small {
  color: #7b818a;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.2;
}

#app.ai-layout .generation-progress-head strong {
  color: #202124;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.18;
  letter-spacing: 0;
}

#app.ai-layout .generation-progress-title p {
  max-width: 58ch;
  margin: 0;
  color: #626873;
  font-size: 13px;
  line-height: 1.65;
  letter-spacing: 0;
}

#app.ai-layout .generation-progress-head b {
  display: inline-grid;
  place-items: center;
  min-width: 52px;
  height: 34px;
  padding: 0 12px;
  color: #202124;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0;
  background: #f4f4f4;
  border: 1px solid #e3e3e3;
  border-radius: 999px;
}

#app.ai-layout .generation-pulse {
  position: relative;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  background: #fafafa;
  border: 1px solid #ececec;
  border-radius: 50%;
}

#app.ai-layout .generation-pulse::before {
  width: 12px;
  height: 12px;
  content: "";
  background: #202124;
  border-radius: 50%;
}

#app.ai-layout .generation-pulse::after {
  position: absolute;
  inset: 8px;
  content: "";
  border: 1px solid rgba(32, 33, 36, 0.28);
  border-radius: 50%;
  animation: generationPulse 1.25s ease-out infinite;
}

#app.ai-layout .generation-progress-detail,
#app.ai-layout .generation-floor-state,
#app.ai-layout .generation-summary-line p {
  margin: 0;
  color: #5d626a;
  font-size: 13px;
  line-height: 1.65;
  letter-spacing: 0;
}

#app.ai-layout .generation-progress-current {
  display: grid;
  gap: 6px;
  padding: 13px 14px;
  background: #f6f6f5;
  border: 1px solid #e9e9e9;
  border-radius: 8px;
}

#app.ai-layout .generation-progress-current span {
  color: #8a9099;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
}

#app.ai-layout .generation-progress-current p {
  margin: 0;
  color: #292c31;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.55;
  letter-spacing: 0;
}

#app.ai-layout .generation-summary-line span {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
  background: #202124;
  border-radius: 50%;
}

#app.ai-layout .generation-progress-bar {
  height: 8px;
  overflow: hidden;
  background: #eeeeee;
  border-radius: 999px;
}

#app.ai-layout .generation-progress-bar span {
  display: block;
  height: 100%;
  background: #202124;
  border-radius: inherit;
  transition: width 0.28s ease;
}

#app.ai-layout .generation-progress-steps {
  box-sizing: border-box;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
  min-width: 0;
  padding: 0;
  margin: 0;
  list-style: none;
}

#app.ai-layout .generation-progress-steps li {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: #b1b4ba;
  padding: 9px 10px;
  background: #f8f8f8;
  border: 1px solid #eeeeee;
  border-radius: 8px;
}

#app.ai-layout .generation-progress-steps li span {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
  background: #c6c9cf;
  border-radius: 50%;
}

#app.ai-layout .generation-progress-steps li strong {
  overflow: hidden;
  min-width: 0;
  color: currentColor;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.25;
  letter-spacing: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#app.ai-layout .generation-progress-steps li.is-active,
#app.ai-layout .generation-progress-steps li.is-done {
  color: #202124;
  background: #ffffff;
  border-color: #dedede;
}

#app.ai-layout .generation-progress-steps li.is-active span,
#app.ai-layout .generation-progress-steps li.is-done span {
  background: #202124;
}

#app.ai-layout .generation-progress-steps li.is-error {
  color: #c2410c;
}

#app.ai-layout .generation-thinking-panel {
  display: grid;
  gap: 10px;
  padding: 14px;
  background: #fafafa;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
}

#app.ai-layout .generation-thinking-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

#app.ai-layout .generation-thinking-head strong {
  color: #202124;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0;
}

#app.ai-layout .generation-thinking-head span {
  color: #8b9098;
  font-size: 12px;
  line-height: 1.4;
  letter-spacing: 0;
}

#app.ai-layout .generation-thinking-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  min-width: 0;
}

#app.ai-layout .generation-thinking-list article {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  min-width: 0;
  padding: 10px 12px;
  background: #ffffff;
  border: 1px solid #ebebeb;
  border-radius: 8px;
}

#app.ai-layout .generation-thinking-list article:nth-child(3) {
  grid-column: auto;
}

#app.ai-layout .generation-thinking-list small {
  padding-top: 1px;
  color: #90959e;
  font-size: 11px;
  font-weight: 750;
  line-height: 1.2;
  letter-spacing: 0;
}

#app.ai-layout .generation-thinking-list p {
  margin: 0;
  overflow-wrap: anywhere;
  color: #343840;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.55;
  letter-spacing: 0;
}

#app.ai-layout .generation-summary-warning {
  display: inline-flex;
  justify-content: center;
  max-width: 100%;
  padding: 5px 8px;
  overflow: hidden;
  color: #62666d;
  font-size: 12px;
  line-height: 1;
  letter-spacing: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: #f3f3f3;
  border-radius: 999px;
}

#app.ai-layout .generation-progress-error {
  margin: 0;
  padding: 12px 14px;
  color: #9f2f20;
  font-size: 13px;
  line-height: 1.55;
  letter-spacing: 0;
  background: #fff0ef;
  border: 1px solid #f4c9c4;
  border-radius: 8px;
}

@keyframes generationPulse {
  from {
    opacity: 0.78;
    transform: scale(0.72);
  }

  to {
    opacity: 0;
    transform: scale(1.55);
  }
}

#app.ai-layout .result-focus {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}

#app.ai-layout .result-focus-frame {
  display: grid;
  width: 100%;
  min-height: 300px;
  padding: 0;
  overflow: hidden;
  background: #f4f4f4;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  cursor: zoom-in;
}

#app.ai-layout .result-focus-frame img {
  width: 100%;
  height: 100%;
  max-height: 460px;
  object-fit: contain;
  background: #f7f7f7;
}

#app.ai-layout .result-focus-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #4e5258;
  font-size: 13px;
  letter-spacing: 0;
}

#app.ai-layout .result-focus-meta strong {
  min-width: 0;
  overflow: hidden;
  color: #24262a;
  font-size: 14px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#app.ai-layout .result-focus-meta a,
#app.ai-layout .result-item a {
  color: #24262a;
  font-size: 12px;
  text-decoration: none;
  white-space: nowrap;
}

#app.ai-layout .result-item-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  min-width: 0;
}

#app.ai-layout .result-item-actions a,
#app.ai-layout .result-item-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  height: 32px;
  padding: 0 8px;
  overflow: hidden;
  color: #24262a;
  font-size: 12px;
  font-weight: 650;
  line-height: 1;
  letter-spacing: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: #ffffff;
  border: 1px solid #dedede;
  border-radius: 6px;
  cursor: pointer;
}

#app.ai-layout .result-item-actions button:hover,
#app.ai-layout .result-item-actions a:hover {
  color: #ffffff;
  background: #202124;
  border-color: #202124;
}

#app.ai-layout .result-image-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

#app.ai-layout .result-item {
  display: grid;
  gap: 7px;
  min-width: 0;
  margin: 0;
}

#app.ai-layout .result-item:last-child:nth-child(odd) {
  grid-column: 1 / -1;
}

#app.ai-layout .result-thumb {
  position: relative;
  display: block;
  width: 100%;
  min-width: 0;
  padding: 0;
  overflow: hidden;
  background: #f2f2f2;
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
}

#app.ai-layout .result-thumb.is-active {
  border-color: #202124;
  box-shadow: 0 0 0 1px #202124;
}

#app.ai-layout .generated-image {
  width: 100%;
  aspect-ratio: 1.28 / 1;
  max-height: none;
  object-fit: cover;
  background: #f2f2f2;
  border: 0;
  border-radius: 5px;
  box-shadow: none;
}

#app.ai-layout .result-thumb span {
  position: absolute;
  left: 8px;
  bottom: 8px;
  padding: 4px 7px;
  color: #ffffff;
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0;
  background: rgba(25, 26, 28, 0.74);
  border-radius: 999px;
}

#app.ai-layout .result-long-card {
  display: grid;
  gap: 10px;
  padding-top: 14px;
  border-top: 1px solid #e5e5e5;
}

#app.ai-layout .result-primary-preview {
  margin-bottom: 16px;
  padding-top: 0;
  border-top: 0;
}

#app.ai-layout .result-separate-list {
  display: grid;
  gap: 10px;
}

#app.ai-layout .result-long-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  letter-spacing: 0;
}

#app.ai-layout .result-long-head strong {
  color: #24262a;
  font-size: 14px;
  font-weight: 650;
}

#app.ai-layout .result-long-head span {
  color: #8a8d91;
  font-size: 12px;
}

#app.ai-layout .result-long-preview {
  display: block;
  width: 100%;
  min-width: 0;
  padding: 0;
  text-align: left;
  background: transparent;
  border: 0;
  cursor: zoom-in;
}

#app.ai-layout .result-long-strip {
  display: grid;
  gap: var(--long-image-gap, 24px);
  max-height: 560px;
  overflow: auto;
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
}

#app.ai-layout .result-long-strip img {
  display: block;
  width: 100%;
  max-height: none;
  object-fit: contain;
  border-bottom: 0;
}

#app.ai-layout .sample-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 16px;
}

#app.ai-layout .sample-composite {
  padding-top: 14px;
}

#app.ai-layout .sample-long-strip {
  display: grid;
  gap: 6px;
}

#app.ai-layout .sample-long-strip .sample-shot {
  min-height: 132px;
}

#app.ai-layout .sample-shot {
  position: relative;
  min-height: 178px;
  margin: 0;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.24)),
    linear-gradient(135deg, #eee7df 0%, #faf8f4 46%, #d8c7b4 100%);
  border-radius: 5px;
}

#app.ai-layout .sample-shot::before {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(90deg, rgba(165, 130, 94, 0.2) 0 2px, transparent 2px 28px),
    linear-gradient(180deg, rgba(255, 255, 255, 0.7), transparent 42%);
  opacity: 0.78;
}

#app.ai-layout .sample-caption {
  position: absolute;
  top: 20px;
  left: 42px;
  z-index: 2;
  display: grid;
  gap: 4px;
  color: #111111;
}

#app.ai-layout .sample-caption strong {
  font-size: 20px;
  font-weight: 900;
}

#app.ai-layout .sample-caption span {
  font-size: 12px;
}

#app.ai-layout .cabinet {
  position: absolute;
  left: 50%;
  bottom: 30px;
  z-index: 1;
  width: 45%;
  height: 38%;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.08) 0 2px, transparent 2px 22px),
    linear-gradient(180deg, #7b4727, #512c19 58%, #2c170f);
  border-radius: 5px;
  box-shadow: 0 14px 30px rgba(44, 27, 17, 0.28);
  transform: translateX(-50%);
}

#app.ai-layout .cabinet i {
  position: absolute;
  inset: 16% 12%;
  border: 2px solid rgba(30, 18, 11, 0.46);
  border-radius: 3px;
}

#app.ai-layout .cabinet.open i {
  left: -18%;
  width: 36%;
  background:
    linear-gradient(90deg, rgba(38, 24, 15, 0.35) 1px, transparent 1px 7px),
    rgba(255, 255, 255, 0.12);
  border-color: rgba(34, 23, 14, 0.55);
}

#app.ai-layout .cabinet.flat {
  bottom: 38px;
  height: 26%;
}

#app.ai-layout .dog,
#app.ai-layout .cat {
  position: absolute;
  z-index: 2;
  background: #f1dfc6;
  border-radius: 48% 48% 45% 45%;
  box-shadow: inset -7px -8px 0 rgba(142, 95, 57, 0.14);
}

#app.ai-layout .dog::before,
#app.ai-layout .dog::after {
  position: absolute;
  content: "";
  background: #8d603c;
  border-radius: 50%;
}

#app.ai-layout .dog::before {
  top: 22%;
  left: 18%;
  width: 18%;
  height: 24%;
}

#app.ai-layout .dog::after {
  top: 22%;
  right: 18%;
  width: 18%;
  height: 24%;
}

#app.ai-layout .dog-a {
  right: 29%;
  bottom: 45%;
  width: 42px;
  height: 50px;
}

#app.ai-layout .dog-b {
  left: 31%;
  bottom: 20%;
  width: 38px;
  height: 45px;
  background: #faf5ed;
}

#app.ai-layout .dog-c {
  left: 35%;
  bottom: 45%;
  width: 96px;
  height: 42px;
  border-radius: 48% 52% 44% 42%;
}

#app.ai-layout .cat {
  right: 24%;
  bottom: 24%;
  width: 34px;
  height: 42px;
  background: #c7a789;
}

#app.ai-layout .plant {
  position: absolute;
  right: 7%;
  top: 22%;
  width: 42px;
  height: 90px;
  border-left: 4px solid #6c7b49;
}

#app.ai-layout .plant::before,
#app.ai-layout .plant::after {
  position: absolute;
  width: 42px;
  height: 22px;
  content: "";
  background: #536b35;
  border-radius: 50%;
  transform: rotate(-22deg);
}

#app.ai-layout .plant::before {
  top: 4px;
  left: -22px;
}

#app.ai-layout .plant::after {
  top: 28px;
  left: 0;
  transform: rotate(24deg);
}

#app.ai-layout .detail-shot,
#app.ai-layout .texture-shot {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0 1px, transparent 1px 18px),
    linear-gradient(135deg, #7a492b, #3d2114);
}

#app.ai-layout .metal {
  position: absolute;
  top: 36%;
  left: 32%;
  width: 102px;
  height: 54px;
  background: linear-gradient(135deg, #b28a59, #4d3827);
  border-radius: 8px;
  box-shadow: 70px 0 0 #6d5034;
}

#app.ai-layout .drops::after {
  position: absolute;
  inset: 24px;
  content: "";
  background:
    radial-gradient(circle at 12% 22%, rgba(255, 255, 255, 0.55) 0 5px, transparent 6px),
    radial-gradient(circle at 38% 52%, rgba(255, 255, 255, 0.45) 0 7px, transparent 8px),
    radial-gradient(circle at 72% 28%, rgba(255, 255, 255, 0.4) 0 5px, transparent 6px),
    radial-gradient(circle at 86% 66%, rgba(255, 255, 255, 0.35) 0 8px, transparent 9px);
}

#app.ai-layout .tabletop {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.06) 0 1px, transparent 1px 20px),
    linear-gradient(135deg, #865332, #4f2c1c);
}

#app.ai-layout .book,
#app.ai-layout .cup,
#app.ai-layout .glasses {
  position: absolute;
  z-index: 2;
}

#app.ai-layout .book {
  left: 25%;
  bottom: 28%;
  width: 110px;
  height: 48px;
  background: #f0e6d9;
  border-radius: 4px;
  transform: rotate(-8deg);
}

#app.ai-layout .cup {
  right: 24%;
  top: 24%;
  width: 44px;
  height: 34px;
  background: #e8ddd0;
  border-radius: 0 0 16px 16px;
}

#app.ai-layout .glasses {
  left: 39%;
  bottom: 37%;
  width: 62px;
  height: 20px;
  border: 3px solid #4a2e23;
  border-right-width: 3px;
  border-radius: 50%;
  box-shadow: 42px 0 0 -3px transparent, 42px 0 0 0 #4a2e23;
}

#app.ai-layout .preview-note {
  display: none;
}

.modal-result-image {
  display: block;
  width: min(78vw, 920px);
  max-width: 100%;
  max-height: 74vh;
  object-fit: contain;
  background: #f5f5f5;
  border-radius: 8px;
}

.modal-result-viewer {
  display: grid;
  gap: 14px;
  justify-items: center;
}

.modal-result-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  width: 100%;
}

.modal-result-actions .primary-btn,
.modal-result-actions .soft-btn {
  min-width: 140px;
  height: 42px;
  margin-top: 0;
}

.modal-result-actions .primary-btn,
.regenerate-actions .primary-btn {
  color: #ffffff;
  background: #202124;
  box-shadow: none;
}

.modal-result-actions .soft-btn,
.regenerate-actions .soft-btn {
  color: #202124;
  background: #ffffff;
  border: 1px solid #dedede;
}

.modal-download-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 160px;
  height: 42px;
  color: #ffffff;
  text-decoration: none;
}

.modal-long-preview {
  display: grid;
  gap: var(--long-image-gap, 24px);
  max-height: 74vh;
  overflow: auto;
  background: #ffffff;
  border-radius: 8px;
}

.modal-long-preview img {
  display: block;
  width: min(78vw, 920px);
  max-width: 100%;
  border-bottom: 0;
}

.modal-result-tip {
  margin: 10px 0 0;
  color: #777777;
  font-size: 13px;
  line-height: 1.6;
  text-align: center;
}

.regenerate-panel {
  display: grid;
  gap: 16px;
}

.regenerate-preview {
  display: grid;
  gap: 8px;
  justify-items: center;
  margin: 0;
  padding: 12px;
  background: #f6f6f6;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
}

.regenerate-preview img {
  display: block;
  width: min(100%, 360px);
  max-height: 280px;
  object-fit: contain;
  background: #ffffff;
  border-radius: 6px;
}

.regenerate-preview figcaption {
  max-width: 100%;
  overflow: hidden;
  color: #6f7378;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.regenerate-field {
  display: grid;
  gap: 8px;
  color: #202124;
  font-size: 14px;
  font-weight: 700;
}

.regenerate-field textarea {
  min-height: 112px;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.6;
}

.regenerate-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.regenerate-actions .primary-btn,
.regenerate-actions .soft-btn {
  width: 100%;
  height: 42px;
  margin-top: 0;
}

body:has(#app.ai-layout:not([hidden])) .app-loading-tip {
  display: none;
}

@media (max-width: 1180px) {
  #app.ai-layout {
    grid-template-areas:
      "sidebar"
      "main";
    grid-template-columns: minmax(0, 1fr);
    background: #ffffff;
  }

  #app.ai-layout .app-sidebar {
    position: static;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    height: auto;
    min-height: 0;
    padding: 8px 16px;
    border-right: 0;
    border-bottom: 1px solid #eeeeee;
  }

  #app.ai-layout .sidebar-brand {
    flex: 0 0 auto;
    gap: 9px;
    padding: 0;
    font-size: 16px;
    white-space: nowrap;
  }

  #app.ai-layout .sidebar-head {
    margin-bottom: 0;
  }

  #app.ai-layout .brand-spark {
    width: 24px;
    height: 24px;
  }

  #app.ai-layout .sidebar-collapse-btn {
    display: none;
  }

  #app.ai-layout .sidebar-nav,
  #app.ai-layout .task-tools,
  #app.ai-layout .plan-card,
  #app.ai-layout .sidebar-footer {
    display: none;
  }

  #app.ai-layout .ops-top-entry {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 82px;
  }

  #app.ai-layout .ops-top-entry.active {
    color: #ffffff;
    background: #202124;
    border-color: #202124;
  }

  #app.ai-layout .commerce-main {
    padding: 10px 14px 16px;
  }

  #app.ai-layout .commerce-header {
    margin-bottom: 12px;
  }

  #app.ai-layout .workspace {
    grid-template-areas:
      "builder"
      "preview";
    grid-template-columns: 1fr;
  }

  #app.ai-layout .video-workspace {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  #app.ai-layout .commerce-header,
  #app.ai-layout .watermark-reference-row,
  #app.ai-layout .form-grid {
    grid-template-columns: 1fr;
  }

  #app.ai-layout .template-card-grid,
  #app.ai-layout .floor-chip-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #app.ai-layout .product-meta-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #app.ai-layout .video-meta-grid,
  #app.ai-layout .video-material-grid,
  #app.ai-layout .video-preview-script article {
    grid-template-columns: 1fr;
  }

  #app.ai-layout .video-shot-list li {
    grid-template-columns: 36px minmax(0, 1fr);
  }

  #app.ai-layout .video-shot-list em {
    grid-column: 2 / -1;
  }

  #app.ai-layout .video-stage {
    min-height: 460px;
    padding: 18px;
  }

  #app.ai-layout .preview-headline {
    align-items: flex-start;
  }

  #app.ai-layout .video-preview-card .preview-headline {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
  }

  #app.ai-layout .video-preview-card .preview-actions {
    justify-content: flex-start;
    gap: 10px;
  }

  #app.ai-layout .commerce-header {
    display: grid;
    gap: 8px;
  }

  #app.ai-layout .commerce-header > div {
    width: 100%;
    min-width: 0;
  }

  #app.ai-layout .commerce-header h1 {
    font-size: 22px;
    white-space: nowrap;
  }

  #app.ai-layout .commerce-header p {
    max-width: 100%;
    margin-top: 4px;
    font-size: 13px;
    white-space: nowrap;
  }

  #app.ai-layout .result-stage.is-generating {
    min-height: 520px;
    padding: 10px;
  }

  #app.ai-layout .result-stage.is-generating .generation-progress-card {
    padding: 16px;
  }

  #app.ai-layout .generation-progress-head {
    grid-template-columns: auto minmax(0, 1fr);
  }

  #app.ai-layout .generation-progress-head b {
    grid-column: 1 / -1;
    justify-self: start;
    width: auto;
    height: 30px;
    padding: 0 12px;
    border-radius: 999px;
  }

  #app.ai-layout .generation-progress-head strong {
    font-size: 20px;
  }

  #app.ai-layout .generation-progress-steps,
  #app.ai-layout .generation-thinking-list {
    grid-template-columns: 1fr;
  }

  #app.ai-layout .generation-thinking-list article:nth-child(3) {
    grid-column: auto;
  }

  #app.ai-layout .generation-thinking-head {
    display: grid;
  }

  #app.ai-layout .top-actions {
    flex-wrap: wrap;
    gap: 8px;
    width: 100%;
    max-width: 100%;
    justify-content: flex-start;
  }

  #app.ai-layout .recharge-chip,
  #app.ai-layout .top-home-btn,
  #app.ai-layout #authBtn,
  #app.ai-layout .gift-btn,
  #app.ai-layout .avatar-btn {
    height: 34px;
  }

  #app.ai-layout .recharge-chip,
  #app.ai-layout .top-home-btn,
  #app.ai-layout #authBtn {
    padding: 0 14px;
  }

  #app.ai-layout .gift-btn,
  #app.ai-layout .avatar-btn {
    width: 36px;
  }

  #app.ai-layout .top-home-btn {
    order: -2;
  }

  #app.ai-layout .credit-display {
    order: -1;
    width: 96px;
    min-width: 96px;
  }

  #app.ai-layout .watermark-reference-row {
    gap: 12px;
  }

  #app.ai-layout .watermark-reference-row > .segmented-field,
  #app.ai-layout .watermark-reference-row > .upload-field {
    padding: 12px;
  }

  #app.ai-layout .custom-watermark-field {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  #app.ai-layout .custom-watermark-field span,
  #app.ai-layout .custom-watermark-field input,
  #app.ai-layout .custom-watermark-field small {
    grid-column: auto;
    grid-row: auto;
  }

  #app.ai-layout .section-title {
    display: grid;
    gap: 6px;
  }

  #app.ai-layout .section-title small {
    text-align: left;
  }

  #app.ai-layout .batch-queue-head,
  #app.ai-layout .batch-queue-actions {
    align-items: stretch;
    flex-direction: column;
  }

  #app.ai-layout .advanced-fixed-label {
    display: grid;
    gap: 4px;
    align-content: center;
    justify-content: stretch;
  }

  #app.ai-layout .advanced-fixed-label small {
    white-space: normal;
  }

  #app.ai-layout .advanced-grid {
    grid-template-columns: 1fr;
    padding: 12px;
  }

  #app.ai-layout .style-tabs,
  #app.ai-layout .sample-gallery,
  #app.ai-layout .result-image-grid {
    grid-template-columns: 1fr;
  }
}

#app.ai-layout .ops-view {
  display: grid;
  gap: 18px;
  min-height: calc(100vh - 96px);
}

#app.ai-layout .ops-view[hidden] {
  display: none;
}

#app.ai-layout .ops-overview {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

#app.ai-layout .ops-overview article,
#app.ai-layout .task-command-bar,
#app.ai-layout .ops-column,
#app.ai-layout .queue-roster,
#app.ai-layout .queue-desk,
#app.ai-layout .queue-panel {
  background: #ffffff;
  border: 1px solid #dedede;
  border-radius: 7px;
}

#app.ai-layout .ops-overview article {
  display: grid;
  gap: 6px;
  min-height: 98px;
  padding: 16px;
}

#app.ai-layout .ops-overview span,
#app.ai-layout .ops-overview em,
#app.ai-layout .ops-task-card em,
#app.ai-layout .ops-task-card p,
#app.ai-layout .queue-card em,
#app.ai-layout .queue-log,
#app.ai-layout .queue-list,
#app.ai-layout .queue-desk-head span {
  color: #777b82;
  font-size: 12px;
  font-style: normal;
  line-height: 1.6;
}

#app.ai-layout .ops-overview strong {
  color: #202124;
  font-size: 28px;
  line-height: 1;
}

#app.ai-layout .task-command-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
}

#app.ai-layout .task-command-bar div {
  display: grid;
  gap: 4px;
}

#app.ai-layout .task-command-bar strong,
#app.ai-layout .queue-desk-head strong {
  color: #202124;
  font-size: 18px;
}

#app.ai-layout .task-command-bar span {
  color: #777b82;
  font-size: 12px;
}

#app.ai-layout .ops-board {
  display: grid;
  grid-template-columns: repeat(4, minmax(210px, 1fr));
  gap: 12px;
  align-items: start;
  overflow-x: auto;
  padding-bottom: 4px;
}

#app.ai-layout .history-record-board {
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  align-items: start;
  gap: 22px 18px;
  max-height: none;
  overflow: visible;
  padding: 0 0 18px;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

#app.ai-layout .history-empty-card,
#app.ai-layout .history-record-card {
  background: #ffffff;
  border: 1px solid #dedede;
  border-radius: 7px;
}

#app.ai-layout .history-empty-card {
  display: grid;
  gap: 10px;
  grid-column: 1 / -1;
  min-height: 220px;
  place-items: center;
  padding: 34px;
  text-align: center;
}

#app.ai-layout .history-empty-card strong {
  color: #202124;
  font-size: 18px;
}

#app.ai-layout .history-empty-card p {
  max-width: 420px;
  margin: 0;
  color: #777b82;
  font-size: 13px;
  line-height: 1.7;
}

#app.ai-layout .history-record-card {
  display: grid;
  grid-template-rows: 212px minmax(0, 1fr);
  gap: 0;
  height: 364px;
  overflow: hidden;
  min-height: 0;
}

#app.ai-layout .history-record-media {
  display: block;
  width: 100%;
  height: 212px;
  min-height: 0;
  padding: 0;
  overflow: hidden;
  background: #f3f3f3;
  border: 0;
  cursor: pointer;
}

#app.ai-layout .history-record-media img,
#app.ai-layout .history-record-media video,
#app.ai-layout .history-record-media .history-final-long-strip,
#app.ai-layout .history-placeholder {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  aspect-ratio: auto;
  object-fit: cover;
}

#app.ai-layout .history-record-media .history-final-long-strip {
  display: grid;
  gap: max(3px, calc(var(--history-long-image-gap, 24px) / 8));
  grid-auto-rows: minmax(0, 1fr);
  height: 100%;
  min-height: 0;
  overflow: hidden;
  background: #ffffff;
}

#app.ai-layout .history-final-long-strip img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  background: #f4f4f4;
}

#app.ai-layout .history-final-long-strip.is-card img {
  aspect-ratio: auto;
}

#app.ai-layout .history-record-media > .history-final-long-image {
  padding: 8px;
  box-sizing: border-box;
  object-fit: contain;
  background: #ffffff;
}

#app.ai-layout .history-record-media > .history-cover-image {
  object-fit: cover;
  background: #f4f4f4;
}

#app.ai-layout .history-record-media > .history-cover-image.is-long-fallback {
  padding: 8px;
  box-sizing: border-box;
  object-fit: contain;
  background: #ffffff;
}

#app.ai-layout .history-placeholder {
  display: grid;
  place-items: center;
  color: #6f747b;
  font-size: 14px;
  font-style: normal;
  font-weight: 700;
  background: linear-gradient(180deg, #f6f6f6 0%, #e7e7e7 100%);
}

#app.ai-layout .history-placeholder.is-missing-result {
  gap: 8px;
  padding: 18px;
  text-align: center;
}

#app.ai-layout .history-placeholder.is-missing-result strong {
  color: #202124;
  font-size: 14px;
}

#app.ai-layout .history-placeholder.is-missing-result span {
  max-width: 260px;
  color: #7b7f86;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.5;
}

#app.ai-layout .history-record-main {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 10px;
  min-width: 0;
  min-height: 0;
  padding: 14px;
  overflow: hidden;
}

#app.ai-layout .history-record-main > div {
  display: grid;
  gap: 6px;
}

#app.ai-layout .history-record-main strong {
  display: -webkit-box;
  overflow: hidden;
  color: #202124;
  font-size: 15px;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

#app.ai-layout .history-record-main em,
#app.ai-layout .history-record-main p,
#app.ai-layout .history-record-main footer span {
  color: #777b82;
  font-size: 12px;
  font-style: normal;
  line-height: 1.6;
}

#app.ai-layout .history-record-main em {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
}

#app.ai-layout .history-record-main p {
  overflow: hidden;
  margin: 0;
  white-space: nowrap;
  text-overflow: ellipsis;
}

#app.ai-layout .history-record-main footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  align-self: end;
  padding-top: 10px;
  border-top: 1px solid #ededed;
}

#app.ai-layout .history-record-main footer span {
  min-width: 0;
  flex: 1 1 130px;
}

#app.ai-layout .history-record-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex: 0 0 auto;
  gap: 8px;
}

#app.ai-layout .history-record-main footer button,
.history-detail-actions button {
  height: 30px;
  padding: 0 12px;
  color: #202124;
  font-size: 12px;
  font-weight: 700;
  background: #ffffff;
  border: 1px solid #d8d8d8;
  border-radius: 6px;
  cursor: pointer;
}

#app.ai-layout .history-record-main footer .history-delete-btn,
.history-detail-actions .history-delete-btn {
  color: #b42318;
  background: #fffafa;
  border-color: #f1c7c2;
}

#app.ai-layout .history-record-main footer .history-delete-btn:hover,
.history-detail-actions .history-delete-btn:hover {
  color: #ffffff;
  background: #b42318;
  border-color: #b42318;
}

.history-detail-panel {
  display: grid;
  gap: 14px;
}

.history-detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.history-detail-meta span {
  padding: 6px 10px;
  color: #3d4045;
  font-size: 12px;
  font-weight: 700;
  background: #f3f3f3;
  border-radius: 999px;
}

.history-detail-media {
  display: grid;
  gap: 10px;
}

.history-final-panel {
  display: grid;
  gap: 10px;
}

.history-final-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.history-final-head strong {
  color: #202124;
  font-size: 14px;
  font-weight: 750;
}

.history-final-head span {
  color: #777b82;
  font-size: 12px;
}

.history-recovery-warning {
  margin: 0;
  padding: 9px 10px;
  color: #7a3b0c;
  font-size: 12px;
  line-height: 1.6;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 7px;
}

.history-final-long-strip.is-modal {
  display: grid;
  gap: var(--history-long-image-gap, 24px);
  max-height: 72vh;
  overflow: auto;
  background: #ffffff;
  border: 1px solid #dedede;
  border-radius: 7px;
}

.history-final-long-strip.is-modal img {
  width: 100%;
  object-fit: contain;
  border: 0;
  border-radius: 0;
}

.history-detail-media img,
.history-detail-media video {
  display: block;
  width: 100%;
  max-height: 72vh;
  object-fit: contain;
  background: #f4f4f4;
  border: 1px solid #dedede;
  border-radius: 7px;
}

.history-detail-media .history-final-long-strip img {
  max-height: none;
  border: 0;
  border-radius: 0;
}

.history-detail-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 4px;
  border-top: 1px solid #ececec;
}

.history-modal-empty {
  display: grid;
  gap: 8px;
  padding: 24px;
  color: #777b82;
  text-align: center;
  background: #f7f7f7;
  border: 1px dashed #d8d8d8;
  border-radius: 7px;
}

.history-modal-empty strong {
  color: #202124;
  font-size: 15px;
}

.history-modal-empty span {
  line-height: 1.7;
}

#app.ai-layout .ops-column {
  display: grid;
  gap: 10px;
  min-width: 210px;
  padding: 12px;
}

#app.ai-layout .ops-column > header,
#app.ai-layout .queue-panel > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 28px;
  color: #202124;
  font-size: 13px;
  font-weight: 700;
}

#app.ai-layout .ops-column > header strong,
#app.ai-layout .queue-panel > header strong {
  display: inline-grid;
  place-items: center;
  min-width: 28px;
  height: 24px;
  color: #ffffff;
  font-size: 12px;
  background: #242529;
  border-radius: 999px;
}

#app.ai-layout .ops-task-card {
  display: grid;
  gap: 10px;
  min-height: 138px;
  padding: 13px;
  background: #f8f8f8;
  border: 1px solid #e6e6e6;
  border-radius: 7px;
}

#app.ai-layout .ops-task-card div:first-child,
#app.ai-layout .ops-task-card footer {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

#app.ai-layout .ops-task-card strong {
  display: block;
  color: #202124;
  font-size: 13px;
  line-height: 1.35;
}

#app.ai-layout .ops-task-card footer {
  align-items: center;
  margin-top: auto;
}

#app.ai-layout .ops-task-card footer span {
  color: #3a3c40;
  font-size: 12px;
  font-weight: 700;
}

#app.ai-layout .ops-task-card button {
  height: 28px;
  padding: 0 10px;
  color: #202124;
  font-size: 12px;
  font-weight: 700;
  background: #ffffff;
  border: 1px solid #d8d8d8;
  border-radius: 6px;
  cursor: pointer;
}

#app.ai-layout .ops-task-card.is-running {
  background: #f5f5f5;
  border-color: #d4d4d4;
}

#app.ai-layout .ops-task-card.is-review {
  background: #fffdf8;
}

#app.ai-layout .ops-task-card.is-done {
  background: #f7f9f7;
}

#app.ai-layout .ops-task-card.is-empty {
  min-height: 118px;
  background: #ffffff;
  border-style: dashed;
}

#app.ai-layout .task-progress {
  height: 7px;
  overflow: hidden;
  background: #e4e4e4;
  border-radius: 999px;
}

#app.ai-layout .task-progress i {
  display: block;
  height: 100%;
  background: #242529;
  border-radius: inherit;
}

#app.ai-layout .concurrency-queue-view {
  grid-template-columns: 240px minmax(0, 1fr);
  align-items: stretch;
}

#app.ai-layout .queue-roster {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 12px;
}

#app.ai-layout .queue-card {
  display: grid;
  gap: 4px;
  min-height: 88px;
  padding: 13px;
  background: #f8f8f8;
  border: 1px solid transparent;
  border-radius: 7px;
  cursor: pointer;
}

#app.ai-layout .queue-card.is-active {
  background: #ffffff;
  border-color: #202124;
}

#app.ai-layout .queue-card:not(.is-empty):hover,
#app.ai-layout .queue-card:not(.is-empty):focus-visible {
  background: #ffffff;
  border-color: #202124;
  outline: none;
}

#app.ai-layout .queue-card.is-empty {
  background: #ffffff;
  border-color: #d9d9d9;
  border-style: dashed;
  cursor: default;
}

#app.ai-layout .queue-card strong {
  color: #202124;
  font-size: 16px;
}

#app.ai-layout .queue-card span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #303236;
  font-size: 13px;
  font-weight: 700;
}

#app.ai-layout .queue-desk {
  display: grid;
  gap: 14px;
  padding: 16px;
}

#app.ai-layout .queue-desk-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

#app.ai-layout .queue-desk-head div {
  display: grid;
  gap: 4px;
}

#app.ai-layout .queue-capacity {
  display: grid;
  gap: 10px;
  padding: 14px;
  background: #f8f8f8;
  border: 1px solid #e4e4e4;
  border-radius: 7px;
}

#app.ai-layout .queue-capacity > div:first-child {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

#app.ai-layout .queue-capacity span {
  color: #555a60;
  font-size: 12px;
  font-weight: 700;
}

#app.ai-layout .queue-capacity strong {
  color: #202124;
  font-size: 18px;
  font-variant-numeric: tabular-nums;
}

#app.ai-layout .queue-capacity p {
  margin: 0;
  color: #777b82;
  font-size: 12px;
  line-height: 1.6;
}

#app.ai-layout .queue-grid {
  display: grid;
  grid-template-columns: minmax(220px, 0.72fr) minmax(320px, 1.2fr) minmax(240px, 0.9fr);
  gap: 12px;
  align-items: stretch;
}

#app.ai-layout .queue-panel {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 14px;
  min-height: 360px;
}

#app.ai-layout .queue-list,
#app.ai-layout .queue-log {
  display: grid;
  gap: 10px;
  padding: 0;
  margin: 0;
  list-style: none;
}

#app.ai-layout .queue-list li,
#app.ai-layout .queue-log li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 38px;
  padding: 0 10px;
  background: #f8f8f8;
  border-radius: 6px;
}

#app.ai-layout .queue-list li.queue-empty {
  color: #858a92;
  background: #ffffff;
  border: 1px dashed #d9d9d9;
}

#app.ai-layout .queue-list span,
#app.ai-layout .queue-log span {
  color: #2e3034;
  font-size: 13px;
  font-weight: 650;
}

#app.ai-layout .queue-list span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}

#app.ai-layout .queue-list em,
#app.ai-layout .queue-log time {
  color: #777b82;
  font-size: 12px;
  font-style: normal;
  white-space: nowrap;
}

#app.ai-layout .queue-output-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

#app.ai-layout .queue-output-grid figure {
  display: grid;
  gap: 8px;
  margin: 0;
}

#app.ai-layout .queue-output-grid i {
  display: block;
  aspect-ratio: 4 / 3;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0) 46%),
    linear-gradient(180deg, #d4c4ad 0%, #7b5134 100%);
  border: 1px solid #d8d0c6;
  border-radius: 7px;
}

#app.ai-layout .queue-output-grid img,
#app.ai-layout .queue-output-grid video {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: #f2f2f2;
  border: 1px solid #d8d0c6;
  border-radius: 7px;
}

#app.ai-layout .queue-output-grid figure.is-video-output i {
  background:
    linear-gradient(160deg, rgba(34, 35, 38, 0.96), rgba(34, 35, 38, 0.5)),
    radial-gradient(circle at 50% 35%, #f0d7a6 0 20%, transparent 21%);
  border-color: #2b2c30;
}

#app.ai-layout .queue-output-grid figure.is-failed-output i {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0) 48%),
    linear-gradient(180deg, #d9d9d9 0%, #8a8d92 100%);
  border-color: #c9c9c9;
}

#app.ai-layout .queue-output-grid figcaption {
  color: #3b3d40;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
}

@media (max-width: 1180px) {
  #app.ai-layout .ops-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #app.ai-layout .history-record-board {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px 16px;
  }

  #app.ai-layout .concurrency-queue-view,
  #app.ai-layout .queue-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  #app.ai-layout .history-record-board {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  #app.ai-layout .product-meta-grid {
    grid-template-columns: 1fr;
  }

  #app.ai-layout .ops-overview {
    grid-template-columns: 1fr;
  }

  #app.ai-layout .task-command-bar,
  #app.ai-layout .queue-desk-head {
    align-items: stretch;
    flex-direction: column;
  }

  #app.ai-layout .history-record-card {
    height: auto;
    min-height: 360px;
  }
}
