:root {
  --bg: #f7f8f7;
  --panel: #ffffff;
  --panel-2: #fbfcfb;
  --text: #20252d;
  --muted: #6d737c;
  --soft: #e7ebe9;
  --line: #dde3e0;
  --teal: #08a99b;
  --teal-2: #0cc7b7;
  --coral: #ff5b50;
  --amber: #f5a623;
  --green: #50a961;
  --blue: #477ad6;
  --danger: #df4a43;
  --shadow: 0 18px 46px rgba(33, 43, 54, 0.08);
  --radius: 8px;
  color: var(--text);
  font-family:
    Inter, "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", Arial,
    sans-serif;
  font-size: 14px;
}

* {
  box-sizing: border-box;
}

html,
body,
#app {
  min-height: 100%;
}

body {
  margin: 0;
  background:
    linear-gradient(rgba(255, 255, 255, 0.72) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.72) 1px, transparent 1px),
    var(--bg);
  background-size: 28px 28px;
  letter-spacing: 0;
}

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

button {
  border: 0;
  cursor: pointer;
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid rgba(8, 169, 155, 0.28);
  outline-offset: 2px;
}

img {
  max-width: 100%;
  display: block;
}

svg {
  display: block;
}

a {
  color: inherit;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 216px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 24px 16px;
  background: rgba(255, 255, 255, 0.88);
  border-right: 1px solid var(--line);
  backdrop-filter: blur(18px);
  overflow: auto;
}

.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 28px;
}

.brand-mark {
  width: 38px;
  height: 38px;
  color: #fff;
  display: grid;
  place-items: center;
  background: #161b22;
  border-radius: 7px;
  box-shadow: inset 0 -10px 20px rgba(255, 255, 255, 0.1);
}

.brand-mark svg {
  width: 22px;
  height: 22px;
}

.brand-title {
  font-weight: 760;
  font-size: 17px;
  line-height: 1.15;
}

.brand-subtitle,
.small,
.muted {
  color: var(--muted);
}

.brand-subtitle {
  font-size: 12px;
  margin-top: 2px;
}

.primary-new {
  width: 100%;
  height: 42px;
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
  background: var(--teal);
  color: #fff;
  border-radius: var(--radius);
  font-weight: 700;
  box-shadow: 0 12px 26px rgba(8, 169, 155, 0.22);
}

.primary-new svg,
.search svg,
.wallet svg,
.asset-actions svg,
.folder-row svg,
.file-actions svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.nav {
  margin: 26px 0;
}

.nav-group {
  display: grid;
  gap: 6px;
  padding: 0 0 18px;
  margin: 0 0 18px;
  border-bottom: 1px solid var(--soft);
}

.nav-btn {
  width: 100%;
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 12px;
  border-radius: var(--radius);
  color: #343a42;
  background: transparent;
  text-align: left;
}

.nav-btn:hover {
  background: #eef7f5;
}

.nav-btn.active {
  background: #e8f6f3;
  color: #058f84;
  font-weight: 700;
}

.nav-btn svg,
.icon-btn svg,
.tool-icon svg,
.button svg {
  width: 18px;
  height: 18px;
  stroke-width: 1.9;
}

.team-card,
.support-card {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: var(--radius);
  padding: 14px;
  margin-top: 14px;
}

.meter {
  height: 5px;
  background: #e5ebe8;
  border-radius: 999px;
  margin: 10px 0 8px;
  overflow: hidden;
}

.meter > span {
  display: block;
  height: 100%;
  width: var(--value, 54%);
  background: var(--teal);
}

.main {
  min-width: 0;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 66px;
  display: grid;
  grid-template-columns: minmax(260px, 520px) minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 0 28px;
  background: rgba(247, 248, 247, 0.86);
  border-bottom: 1px solid rgba(221, 227, 224, 0.8);
  backdrop-filter: blur(16px);
}

.search {
  position: relative;
}

.search svg {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #7b828b;
  stroke-width: 1.9;
}

.search input {
  width: 100%;
  height: 38px;
  padding: 0 48px 0 42px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
}

.slash {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--muted);
  font-size: 12px;
}

.top-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.wallet {
  height: 42px;
  min-width: 164px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 10px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.wallet strong {
  display: block;
  font-size: 16px;
}

.wallet button {
  margin-left: auto;
  height: 28px;
  padding: 0 12px;
  border-radius: 7px;
  color: #fff;
  background: var(--teal);
  font-weight: 700;
}

.icon-btn {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: #3e464d;
}

.avatar {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 134px;
  padding-left: 8px;
}

.avatar-face {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(140deg, #263238, #08a99b);
  color: #fff;
  font-weight: 800;
}

.avatar strong {
  display: block;
  line-height: 1.15;
}

.content {
  padding: 22px 28px 42px;
}

.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  gap: 28px;
  align-items: start;
}

.page-title {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin: 8px 0 18px;
}

.page-title h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.18;
  font-weight: 760;
}

.page-title p {
  margin: 6px 0 0;
  color: var(--muted);
}

.panel {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.panel.flat {
  box-shadow: none;
}

.panel-head {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--soft);
}

.panel-head h2,
.panel-head h3,
.section-title {
  margin: 0;
  font-size: 16px;
  font-weight: 760;
}

.panel-body {
  padding: 16px;
}

.design-panel {
  padding: 16px;
}

.prompt-box {
  display: grid;
  gap: 10px;
}

.prompt-box textarea {
  width: 100%;
  min-height: 96px;
  resize: vertical;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  background: #fff;
  line-height: 1.55;
}

.prompt-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.char-count {
  margin-left: auto;
  color: #9aa1aa;
  font-size: 12px;
}

.button {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  border-radius: var(--radius);
  background: #fff;
  border: 1px solid var(--line);
  color: var(--text);
  font-weight: 660;
  text-decoration: none;
}

.button:hover {
  border-color: #b8c4c0;
}

.button.primary {
  border-color: transparent;
  color: #fff;
  background: var(--teal);
}

.button.coral {
  border-color: transparent;
  color: #fff;
  background: var(--coral);
}

.button.ghost {
  background: transparent;
}

.button.slim {
  min-height: 30px;
  padding: 0 10px;
  font-size: 12px;
}

.button.block {
  width: 100%;
}

.button[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  min-height: 36px;
  padding: 0 16px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
  color: #3a424a;
}

.chip.active {
  border-color: var(--teal);
  color: #058f84;
  background: #effaf8;
  font-weight: 700;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
  border: 1px solid var(--soft);
  border-radius: var(--radius);
  padding: 14px;
  background: #fff;
}

@media (min-width: 1500px) {
  .form-grid {
    grid-template-columns: 1.1fr 1fr 1.05fr 0.9fr;
  }
}

.field-label {
  display: block;
  margin-bottom: 10px;
  color: #39414a;
  font-weight: 720;
}

.dropzone {
  min-height: 160px;
  display: grid;
  place-items: center;
  text-align: center;
  border: 1px dashed #cad3cf;
  border-radius: var(--radius);
  background: #fbfcfb;
  padding: 14px;
  color: var(--muted);
}

.dropzone strong {
  color: var(--text);
}

.dropzone svg {
  width: 28px;
  height: 28px;
  margin: 0 auto 8px;
}

.dropzone input {
  display: none;
}

.option-stack {
  display: grid;
  gap: 10px;
}

.model-option,
.ratio-option,
.style-option {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  background: #fbfcfb;
  border-radius: var(--radius);
  text-align: left;
}

.model-option.active,
.ratio-option.active,
.style-option.active {
  border-color: var(--teal);
  background: #effaf8;
}

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

.style-preview {
  width: 48px;
  height: 42px;
  border-radius: 7px;
  flex: 0 0 auto;
  background: var(--preview);
}

.generate-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  margin-top: 14px;
}

.generate-bar .button {
  height: 44px;
  font-size: 15px;
}

.results-head,
.section-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 20px 0 12px;
}

.tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.tab {
  height: 32px;
  padding: 0 12px;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
}

.tab.active {
  color: var(--teal);
  background: #e9f7f5;
  font-weight: 700;
}

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

.asset-card {
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.asset-art {
  aspect-ratio: 4 / 5;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 18px;
  overflow: hidden;
  color: #275a38;
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 255, 255, 0.84), transparent 36%),
    linear-gradient(140deg, var(--c1), var(--c2));
}

.asset-art::before,
.asset-art::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.52);
}

.asset-art::before {
  width: 118px;
  height: 118px;
  right: -34px;
  top: 48px;
}

.asset-art::after {
  width: 86px;
  height: 86px;
  left: 18px;
  bottom: 60px;
}

.asset-title {
  position: relative;
  z-index: 1;
  font-size: 24px;
  font-weight: 820;
  line-height: 1.12;
}

.asset-price {
  position: relative;
  z-index: 1;
  width: 70px;
  height: 70px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: rgba(8, 169, 155, 0.88);
  font-size: 20px;
  font-weight: 800;
}

.asset-actions {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--soft);
}

.asset-actions button {
  height: 38px;
  display: grid;
  place-items: center;
  background: #fff;
  color: #5c646d;
}

.asset-actions button:hover {
  color: var(--teal);
  background: #f3faf8;
}

.right-rail {
  display: grid;
  gap: 16px;
}

.quick-tools {
  display: grid;
  gap: 10px;
}

.tool-item {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-align: left;
}

.tool-item:hover {
  border-color: #b7c8c4;
}

.tool-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  color: #fff;
  background: var(--tool);
}

.tool-icon svg {
  width: 24px;
  height: 24px;
}

.tool-item strong {
  display: block;
  margin-bottom: 4px;
}

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

.task-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--soft);
  border-radius: var(--radius);
  background: #fff;
}

.status {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.status.done {
  color: #058f84;
  background: #e7f7f4;
}

.status.working {
  color: #b36b00;
  background: #fff4df;
}

.status.fail {
  color: #bf3830;
  background: #ffeceb;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  gap: 24px;
  align-items: stretch;
}

.hero-copy {
  padding: 34px;
  min-height: 360px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-copy h1 {
  max-width: 720px;
  margin: 0;
  font-size: 42px;
  line-height: 1.08;
  font-weight: 820;
}

.hero-copy p {
  max-width: 620px;
  margin: 18px 0 24px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.hero-board {
  padding: 24px;
  display: grid;
  gap: 14px;
  min-height: 360px;
}

.mini-window {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 14px;
}

.window-strip {
  height: 8px;
  width: 54%;
  border-radius: 999px;
  background: #e1e7e4;
}

.visual-stack {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.visual-tile {
  min-height: 112px;
  border-radius: var(--radius);
  background: linear-gradient(140deg, var(--c1), var(--c2));
  padding: 14px;
  color: #16322f;
  display: flex;
  align-items: flex-end;
  font-weight: 760;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 16px;
}

.stat {
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.stat strong {
  display: block;
  font-size: 24px;
  margin-bottom: 6px;
}

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

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
}

.card h3 {
  margin: 0 0 8px;
  font-size: 16px;
}

.card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.input,
.select {
  height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--text);
  padding: 0 12px;
}

.templates-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.template-card .asset-art {
  aspect-ratio: 3 / 4;
}

.template-meta {
  padding: 10px;
}

.template-meta strong {
  display: block;
  margin-bottom: 4px;
}

.tools-layout {
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.tool-switcher {
  display: grid;
  gap: 10px;
}

.tool-switcher button {
  min-height: 74px;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  text-align: left;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.tool-switcher button.active {
  border-color: var(--teal);
  background: #effaf8;
}

.preview-stage {
  min-height: 420px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.preview-box {
  min-height: 360px;
  display: grid;
  place-items: center;
  border: 1px dashed #cad3cf;
  border-radius: var(--radius);
  background: #fbfcfb;
  overflow: hidden;
  padding: 16px;
  text-align: center;
  color: var(--muted);
}

.mock-image {
  width: 100%;
  max-width: 320px;
  aspect-ratio: 1;
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.55), transparent),
    linear-gradient(140deg, var(--c1), var(--c2));
  display: grid;
  place-items: center;
  color: #24413f;
  font-weight: 800;
  font-size: 28px;
}

.mock-image.sharp {
  filter: contrast(1.12) saturate(1.12);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.45);
}

.mock-vector {
  width: 100%;
  max-width: 320px;
}

.draw-area {
  position: relative;
  width: 100%;
  max-width: 360px;
  aspect-ratio: 1;
  border-radius: var(--radius);
  background:
    linear-gradient(140deg, #bfece1, #ffdf9f),
    repeating-linear-gradient(45deg, transparent, transparent 12px, rgba(255, 255, 255, 0.2) 12px, rgba(255, 255, 255, 0.2) 24px);
}

.draw-mask {
  position: absolute;
  left: 42%;
  top: 34%;
  width: 34%;
  height: 26%;
  border: 2px solid var(--coral);
  border-radius: 18px;
  background: rgba(255, 91, 80, 0.15);
}

.workspace-layout {
  display: grid;
  grid-template-columns: 245px minmax(0, 1fr);
  gap: 18px;
}

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

.folder-row {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: space-between;
  padding: 0 10px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
}

.folder-row.active {
  border-color: var(--teal);
  color: #058f84;
  background: #effaf8;
  font-weight: 700;
}

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

.file-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.file-thumb {
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, var(--c1), var(--c2));
  display: grid;
  place-items: center;
  font-weight: 800;
  color: #183935;
}

.file-meta {
  padding: 12px;
}

.file-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.table {
  width: 100%;
  border-collapse: collapse;
}

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

.table th {
  color: var(--muted);
  font-size: 12px;
  font-weight: 720;
}

.member-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 18px;
}

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

.price-card {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.price-card.featured {
  border-color: var(--teal);
  box-shadow: 0 16px 34px rgba(8, 169, 155, 0.14);
}

.price {
  font-size: 30px;
  font-weight: 820;
}

.records {
  display: grid;
  gap: 8px;
}

.record-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  padding: 10px 0;
  border-bottom: 1px solid var(--soft);
}

.agreement-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 18px;
  align-items: start;
}

.agreement-row {
  width: 100%;
  background: transparent;
  text-align: left;
}

.story-grid,
.topic-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

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

.story-card {
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.story-card h3 {
  margin: 0 0 8px;
}

.story-card p {
  margin: 0 0 12px;
  color: var(--muted);
  line-height: 1.65;
}

.app-card {
  display: grid;
  gap: 12px;
  align-content: start;
}

.app-badge {
  width: 76px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  color: #fff;
  background: #20252d;
  font-weight: 800;
  font-size: 12px;
}

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

.timeline > div {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(20, 26, 32, 0.36);
}

.modal {
  width: min(520px, 100%);
  max-height: calc(100vh - 48px);
  overflow: auto;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.22);
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 1px solid var(--soft);
}

.modal-body {
  padding: 18px;
}

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

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

.form.two-col textarea,
.form.two-col .dropzone {
  grid-column: 1 / -1;
}

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

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

.qr {
  width: 172px;
  height: 172px;
  margin: 14px auto;
  border: 10px solid #fff;
  border-radius: 6px;
  background:
    linear-gradient(90deg, #111 12px, transparent 12px) 0 0 / 24px 24px,
    linear-gradient(#111 12px, transparent 12px) 0 0 / 24px 24px,
    #fff;
  box-shadow: 0 0 0 1px var(--line);
}

.empty {
  min-height: 160px;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--muted);
}

#toast-root {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 80;
  display: grid;
  gap: 10px;
}

.toast {
  min-width: 230px;
  padding: 12px 14px;
  color: #fff;
  background: #20252d;
  border-radius: var(--radius);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.18);
}

.toast.success {
  background: #058f84;
}

.toast.error {
  background: var(--danger);
}

.mobile-menu {
  display: none;
}

@media (max-width: 1180px) {
  .workspace-grid,
  .member-layout,
  .hero,
  .tools-layout,
  .agreement-layout {
    grid-template-columns: 1fr;
  }

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

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

  .result-grid,
  .file-grid,
  .story-grid,
  .topic-board {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

@media (max-width: 860px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 50;
    width: 250px;
    transform: translateX(-100%);
    transition: transform 0.22s ease;
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .mobile-menu {
    display: grid;
  }

  .topbar {
    grid-template-columns: 38px minmax(0, 1fr) 38px;
    padding: 0 14px;
  }

  .top-spacer {
    display: none;
  }

  .top-actions {
    min-width: 0;
    gap: 6px;
  }

  .top-actions .wallet,
  .avatar div:not(.avatar-face),
  .top-actions .hide-sm {
    display: none;
  }

  .avatar {
    width: 38px;
    min-width: 38px;
    height: 38px;
    justify-content: center;
    padding-left: 0;
  }

  .content {
    padding: 16px 14px 32px;
  }

  .page-title {
    align-items: start;
    flex-direction: column;
  }

  .hero-copy {
    padding: 24px;
  }

  .hero-copy h1 {
    font-size: 32px;
  }

  .stat-grid,
  .cards-grid,
  .pricing-grid,
  .right-rail,
  .preview-stage,
  .workspace-layout,
  .timeline,
  .form.two-col {
    grid-template-columns: 1fr;
  }

  .result-grid,
  .templates-grid,
  .file-grid,
  .story-grid,
  .topic-board {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (max-width: 540px) {
  .topbar {
    height: auto;
    min-height: 64px;
    gap: 10px;
  }

  .search input {
    padding-right: 14px;
  }

  .slash {
    display: none;
  }

  .result-grid,
  .templates-grid,
  .file-grid,
  .story-grid,
  .topic-board {
    grid-template-columns: 1fr;
  }

  .style-grid,
  .ratio-grid,
  .visual-stack {
    grid-template-columns: 1fr;
  }

  .generate-bar {
    grid-template-columns: 1fr;
  }
}
