:root {
  color-scheme: dark;
  --bg: #090a0f;
  --surface: #12131a;
  --surface-2: #1a1b24;
  --line: rgba(255, 255, 255, 0.12);
  --text: #f7f3f5;
  --muted: #bdb4ba;
  --pink: #e94b73;
  --gold: #d7a857;
  --danger: #ff6b6b;
  --ok: #7bd88f;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(115deg, rgba(233, 75, 115, 0.12), transparent 34%),
    linear-gradient(160deg, transparent 54%, rgba(233, 75, 115, 0.08) 72%, transparent 100%),
    linear-gradient(140deg, #090a0f 0%, #101119 54%, #130d13 100%);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

a {
  color: inherit;
}

.shell {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 48px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  font-weight: 700;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 64% 35%, #ffd4de 0 9%, transparent 10%),
    radial-gradient(circle at 48% 50%, var(--pink) 0 42%, #8f315c 43% 100%);
  box-shadow: 0 0 28px rgba(233, 75, 115, 0.36);
}

.nav {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav a,
.button {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 14px;
  background: rgba(255, 255, 255, 0.05);
  text-decoration: none;
  font-size: 14px;
}

.button.primary {
  border-color: transparent;
  background: var(--pink);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 14px 32px rgba(233, 75, 115, 0.28);
}

.hero,
.grid,
.status-grid {
  display: grid;
  gap: 16px;
}

.hero {
  grid-template-columns: minmax(320px, 0.82fr) minmax(0, 1.18fr);
  align-items: start;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(26, 27, 36, 0.92), rgba(12, 13, 19, 0.92));
  padding: 22px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.24);
}

.panel h1,
.panel h2,
.panel h3 {
  margin: 0 0 12px;
  line-height: 1.2;
}

.panel h1 {
  font-size: clamp(28px, 3.2vw, 44px);
}

.panel p {
  margin: 0 0 14px;
  color: var(--muted);
  line-height: 1.7;
}

.api-path {
  overflow-wrap: anywhere;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  line-height: 1.5;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

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

.preview img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 340px;
  object-fit: cover;
}

.grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 16px;
}

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

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 999px;
  padding: 0 10px;
  background: rgba(215, 168, 87, 0.15);
  color: var(--gold);
  font-size: 12px;
  font-weight: 700;
}

.badge.ok {
  background: rgba(123, 216, 143, 0.14);
  color: var(--ok);
}

.badge.blocked {
  background: rgba(255, 107, 107, 0.14);
  color: var(--danger);
}

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

.list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
  color: var(--muted);
}

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

.field {
  display: grid;
  gap: 6px;
}

.field label {
  color: var(--muted);
  font-size: 13px;
}

.field input {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  background: #0d0e14;
  color: var(--text);
}

.notice {
  border-left: 3px solid var(--pink);
  padding: 12px 14px;
  background: rgba(233, 75, 115, 0.09);
  color: var(--muted);
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 0;
}

.mobile-first-note {
  display: none;
}

.hero-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 24px;
}

.hero-kpis strong {
  display: block;
  font-size: 20px;
  line-height: 1.2;
}

.hero-kpis span {
  color: var(--muted);
  font-size: 12px;
}

.direction-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  align-content: start;
}

.direction-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(233, 75, 115, 0.1), transparent 34%),
    linear-gradient(180deg, #12131a, #090a0f);
  padding: 14px;
}

.direction-card.wide {
  grid-column: 1 / -1;
}

.direction-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
  color: #ff9aaa;
  font-weight: 700;
}

.phone-frame {
  width: min(100%, 260px);
  min-height: 430px;
  margin: 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 30px;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.06), transparent 18%),
    #0d0e14;
  padding: 16px 14px 14px;
  box-shadow: inset 0 0 0 4px rgba(255, 255, 255, 0.035), 0 26px 60px rgba(0, 0, 0, 0.32);
}

.phone-head,
.phone-tabs,
.bottom-nav,
.quick-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.phone-head {
  justify-content: space-between;
  margin-bottom: 14px;
}

.phone-title {
  font-size: 18px;
  font-weight: 700;
}

.icon-dot {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(233, 75, 115, 0.14);
  color: #ff9aaa;
}

.search-line {
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
  margin-bottom: 12px;
}

.phone-tabs {
  overflow: hidden;
  margin-bottom: 12px;
}

.chip {
  flex: 0 0 auto;
  min-height: 28px;
  border-radius: 999px;
  padding: 5px 10px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  font-size: 12px;
}

.chip.active {
  background: var(--pink);
  color: #fff;
}

.role-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.role-card {
  min-height: 132px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background:
    linear-gradient(160deg, rgba(247, 187, 197, 0.28), transparent 42%),
    linear-gradient(180deg, #1a1b24, #0f1017);
  padding: 10px;
}

.role-card:nth-child(2),
.role-card:nth-child(4) {
  background:
    linear-gradient(145deg, rgba(233, 75, 115, 0.24), transparent 44%),
    linear-gradient(180deg, #21161d, #0f1017);
}

.role-avatar {
  display: grid;
  height: 76px;
  place-items: center;
  border-radius: 12px;
  background:
    linear-gradient(145deg, rgba(255, 154, 170, 0.24), transparent 48%),
    linear-gradient(90deg, #222631, #101118);
  color: #ffd7df;
  font-size: 24px;
  font-weight: 800;
  margin-bottom: 10px;
}

.role-card-name,
.role-card-meta {
  min-width: 0;
  overflow-wrap: anywhere;
}

.role-card-name {
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.role-card-meta {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
  margin-top: 4px;
}

.warm-role-card {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(233, 75, 115, 0.26);
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(233, 75, 115, 0.18), transparent 58%),
    rgba(255, 255, 255, 0.045);
  padding: 12px;
}

.warm-role-card h3,
.warm-role-card p {
  margin: 0;
}

.warm-role-card h3 {
  font-size: 16px;
}

.warm-role-card p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

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

.mini-tags span {
  min-height: 22px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #ffb2c1;
  padding: 4px 8px;
  font-size: 11px;
}

.role-detail-lines {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.role-detail-lines span {
  min-width: 0;
  border-left: 2px solid rgba(233, 75, 115, 0.52);
  border-radius: 8px;
  background: rgba(9, 10, 15, 0.42);
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
  overflow-wrap: anywhere;
  padding: 6px 8px;
}

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

.role-detail-actions span {
  display: grid;
  min-height: 32px;
  place-items: center;
  border-radius: 10px;
  background: var(--pink);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}

.role-detail-actions span:first-child {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.07);
  color: var(--text);
}

.repository-note {
  border-radius: 10px;
  background: rgba(9, 10, 15, 0.38);
  color: #c9c0c8;
  font-size: 11px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  padding: 7px 8px;
}

.payment-result-shell {
  grid-template-columns: minmax(300px, 0.78fr) minmax(0, 1.22fr);
}

.payment-result-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.pay-state-card {
  display: grid;
  align-content: start;
  min-height: 164px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.045);
  padding: 14px;
}

.pay-state-card.is-current {
  border-color: rgba(215, 168, 87, 0.36);
  background: rgba(215, 168, 87, 0.08);
}

.pay-state-card.blocked {
  border-color: rgba(255, 107, 107, 0.28);
  background: rgba(255, 107, 107, 0.07);
}

.pay-state-card h2 {
  margin: 10px 0 8px;
  font-size: 18px;
}

.pay-state-card p,
.direction-card p {
  color: var(--muted);
  line-height: 1.65;
  margin: 0;
  overflow-wrap: anywhere;
}

.gate-list {
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
}

.gate-list span {
  border-radius: 10px;
  background: rgba(9, 10, 15, 0.48);
  color: #ffb2c1;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  padding: 8px;
}

.payment-result-summary {
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
}

.payment-result-summary span {
  display: grid;
  grid-template-columns: minmax(74px, 0.34fr) minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 10px;
  background: rgba(9, 10, 15, 0.42);
  color: #f0dce5;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  padding: 7px 8px;
}

.payment-result-summary strong {
  color: #ffb2c1;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 11px;
  font-weight: 700;
}

.skeleton-line {
  height: 8px;
  width: 72%;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}

.skeleton-line.short {
  width: 44%;
  margin-top: 7px;
}

.bottom-nav {
  justify-content: space-around;
  min-height: 48px;
  margin-top: 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
}

.bottom-nav .create {
  display: grid;
  place-items: center;
  width: 48px;
  height: 34px;
  border-radius: 999px;
  background: var(--pink);
  color: #fff;
  font-weight: 700;
}

.chat-hero {
  display: grid;
  gap: 12px;
  padding-top: 14px;
}

.avatar-glow {
  width: 78px;
  height: 78px;
  margin: 0 auto;
  border-radius: 50%;
  background:
    radial-gradient(circle at 62% 36%, #ffd7df 0 8%, transparent 9%),
    linear-gradient(145deg, #332a35, #0f1017);
  box-shadow: 0 0 36px rgba(233, 75, 115, 0.42);
}

.chat-context-preview {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(233, 75, 115, 0.24);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.045);
  padding: 11px;
}

.chat-context-preview h3 {
  margin: 0;
  font-size: 15px;
}

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

.context-grid span {
  min-width: 0;
  border-radius: 8px;
  background: rgba(9, 10, 15, 0.42);
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  padding: 6px 7px;
}

.memory-control-preview {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(215, 168, 87, 0.22);
  border-radius: 14px;
  background: rgba(215, 168, 87, 0.07);
  padding: 11px;
}

.memory-control-preview p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.memory-control-preview div {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.memory-control-preview div span {
  display: grid;
  min-height: 28px;
  place-items: center;
  border-radius: 8px;
  background: rgba(9, 10, 15, 0.44);
  color: #f5d08a;
  font-size: 11px;
  font-weight: 700;
}

.novel-dialogue-preview {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(233, 75, 115, 0.18);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 247, 250, 0.98), rgba(255, 242, 247, 0.96));
  color: #30282e;
  padding: 10px;
}

.novel-chat-head {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  color: #3b3037;
  font-size: 12px;
}

.novel-chat-head strong,
.novel-chat-head span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.avatar-mini {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(145deg, #e94b73, #7d2d50);
  color: #fff;
  font-weight: 800;
}

.novel-user-bubble {
  justify-self: end;
  max-width: 78%;
  border: 1px solid rgba(150, 92, 112, 0.18);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.66);
  color: #4a3d45;
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  padding: 8px 10px;
}

.novel-dialogue-card {
  border: 1px solid rgba(150, 92, 112, 0.2);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.7);
  padding: 12px;
}

.novel-dialogue-card p {
  margin: 0 0 10px;
  color: #312a30;
  font-size: 13px;
  line-height: 1.85;
  overflow-wrap: anywhere;
}

.novel-dialogue-card p:last-of-type {
  margin-bottom: 0;
}

.novel-state-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin-top: 10px;
}

.novel-state-strip span {
  min-width: 0;
  border-radius: 8px;
  background: rgba(233, 75, 115, 0.08);
  color: #76505d;
  font-size: 11px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  padding: 6px 7px;
}

.preference-preview-section {
  display: grid;
  gap: 16px;
  margin-top: 16px;
}

.preference-preview-board {
  display: grid;
  grid-template-columns: minmax(280px, 0.78fr) minmax(280px, 1fr);
  gap: 16px;
  align-items: stretch;
}

.settings-phone-surface {
  border: 1px solid rgba(233, 75, 115, 0.2);
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(255, 250, 252, 0.98), rgba(255, 241, 247, 0.97)),
    #fff8fb;
  color: #2f2930;
  padding: 18px;
  box-shadow: 0 22px 52px rgba(233, 75, 115, 0.14);
}

.settings-preview-head {
  display: flex;
  align-items: center;
  gap: 26px;
  margin-bottom: 20px;
  color: #2d2730;
  font-size: 24px;
  font-weight: 800;
}

.settings-preview-head span {
  font-size: 30px;
  line-height: 1;
}

.settings-card {
  border: 1px solid rgba(137, 87, 105, 0.2);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.56);
  padding: 18px;
}

.settings-card h3,
.settings-card p {
  margin: 0;
}

.settings-card h3 {
  color: #2b252c;
  font-size: 22px;
  line-height: 1.25;
}

.settings-card p {
  margin-top: 8px;
  color: #756b72;
  font-size: 14px;
  line-height: 1.6;
}

.settings-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.setting-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  min-height: 76px;
  border: 1px solid rgba(137, 87, 105, 0.18);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.72);
  padding: 13px 14px;
}

.setting-row span {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.setting-row strong {
  color: #272129;
  font-size: 17px;
  line-height: 1.25;
}

.setting-row small {
  color: #70676f;
  font-size: 13px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.toggle {
  position: relative;
  width: 56px;
  height: 32px;
  flex: 0 0 auto;
  border: 0;
  border-radius: 999px;
  background: #efd3df;
  cursor: default;
}

.toggle::after {
  position: absolute;
  top: 5px;
  left: 6px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #be5a86;
  content: "";
  transition: transform 0.16s ease;
}

.toggle.is-on::after {
  transform: translateX(22px);
}

.setting-link em {
  color: #6d6168;
  font-style: normal;
  font-size: 15px;
  white-space: nowrap;
}

.preference-boundary {
  align-self: stretch;
}

.entitlement-preview {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(255, 107, 107, 0.24);
  border-radius: 14px;
  background: rgba(255, 107, 107, 0.07);
  padding: 11px;
}

.entitlement-preview p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.bubble {
  max-width: 82%;
  border-radius: 18px;
  padding: 13px 14px;
  background: var(--surface-2);
  color: var(--muted);
  line-height: 1.5;
  font-size: 13px;
}

.bubble.me {
  justify-self: end;
  background: linear-gradient(135deg, #e94b73, #b83d62);
  color: #fff;
}

.composer {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  margin-top: 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  padding: 6px 8px 6px 14px;
  color: var(--muted);
}

.send {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--pink);
  color: #fff;
  margin-left: auto;
}

.member-stack {
  display: grid;
  gap: 12px;
}

.member-card {
  min-height: 94px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background:
    linear-gradient(120deg, rgba(215, 168, 87, 0.28), transparent 62%),
    #151219;
  padding: 14px;
}

.member-card.pink {
  background:
    linear-gradient(120deg, rgba(233, 75, 115, 0.3), transparent 62%),
    #171018;
}

.benefits {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.benefits span {
  display: grid;
  place-items: center;
  min-height: 42px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.07);
  color: #ffb2c1;
}

.admin-preview {
  min-height: 430px;
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr);
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #0e1117;
  padding: 14px;
}

.direction-card.wide .admin-preview {
  min-height: 260px;
}

.admin-side {
  display: grid;
  align-content: start;
  gap: 10px;
  border-right: 1px solid var(--line);
  padding-right: 12px;
}

.admin-side span {
  min-height: 28px;
  border-radius: 8px;
  padding: 6px 8px;
  color: var(--muted);
  font-size: 12px;
}

.admin-side span.active {
  background: rgba(233, 75, 115, 0.2);
  color: #ff9aaa;
}

.admin-main {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.filter-row,
.table-row {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 0.8fr 0.6fr;
  gap: 10px;
}

.filter-row span,
.table-row span {
  min-height: 32px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.07);
}

.table-row {
  align-items: center;
  border-bottom: 1px solid var(--line);
  padding-bottom: 8px;
}

.role-workshop-row {
  display: grid;
  grid-template-columns: 1.2fr 1fr 0.7fr;
  gap: 10px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  padding: 9px 0;
  min-width: 0;
}

.role-workshop-row strong,
.role-workshop-row span,
.role-workshop-row em {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 12px;
}

.role-workshop-row span {
  color: var(--muted);
}

.role-workshop-row em {
  justify-self: start;
  border-radius: 999px;
  background: rgba(215, 168, 87, 0.14);
  color: var(--gold);
  padding: 5px 8px;
  font-style: normal;
}

.drawer {
  align-self: end;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #151922;
  padding: 14px;
}

.drawer .button {
  width: 100%;
  margin-top: 12px;
}

.launch-flow,
.delivery-gate {
  display: grid;
  gap: 16px;
  margin-top: 16px;
}

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

.flow-step {
  display: grid;
  gap: 10px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 14px;
  background:
    linear-gradient(140deg, rgba(215, 168, 87, 0.12), transparent 42%),
    linear-gradient(180deg, rgba(20, 22, 31, 0.96), rgba(10, 11, 17, 0.96));
  padding: 16px;
}

.flow-step.is-current {
  border-color: rgba(123, 216, 143, 0.32);
  background:
    linear-gradient(140deg, rgba(123, 216, 143, 0.13), transparent 45%),
    linear-gradient(180deg, rgba(20, 22, 31, 0.96), rgba(10, 11, 17, 0.96));
}

.flow-step.blocked {
  border-color: rgba(255, 107, 107, 0.24);
  background:
    linear-gradient(140deg, rgba(255, 107, 107, 0.1), transparent 44%),
    linear-gradient(180deg, rgba(20, 22, 31, 0.96), rgba(10, 11, 17, 0.96));
}

.flow-step > span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: #ffb2c1;
  font-size: 12px;
  font-weight: 800;
}

.flow-step h3,
.flow-step p {
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
}

.flow-step h3 {
  font-size: 16px;
  line-height: 1.25;
}

.flow-step p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}

.flow-step a {
  align-self: end;
  min-width: 0;
  color: #ffb2c1;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
  overflow-wrap: anywhere;
  text-decoration: none;
}

.review-workbench {
  display: grid;
  gap: 16px;
  margin-top: 16px;
}

.section-heading {
  display: grid;
  gap: 8px;
  max-width: 760px;
}

.section-heading h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.2;
}

.section-heading p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.review-layout {
  display: grid;
  grid-template-columns: minmax(240px, 0.9fr) minmax(300px, 1.2fr) minmax(260px, 0.9fr);
  gap: 14px;
}

.review-queue,
.review-detail,
.publish-gate {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(20, 22, 31, 0.96), rgba(10, 11, 17, 0.96));
  padding: 16px;
}

.review-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 30px;
  margin-bottom: 12px;
}

.review-toolbar strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.review-toolbar span {
  flex: 0 0 auto;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  color: var(--muted);
  font-size: 12px;
  padding: 5px 8px;
}

.review-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid transparent;
  border-bottom-color: var(--line);
  padding: 10px 0;
}

.review-row.is-selected {
  border-color: rgba(233, 75, 115, 0.3);
  border-radius: 10px;
  background: rgba(233, 75, 115, 0.08);
  padding: 10px;
}

.review-row strong,
.review-row p,
.review-row em {
  min-width: 0;
  overflow-wrap: anywhere;
}

.review-row p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.review-row em {
  border-radius: 999px;
  background: rgba(215, 168, 87, 0.14);
  color: var(--gold);
  font-size: 12px;
  font-style: normal;
  padding: 5px 8px;
}

.review-row em.warning {
  background: rgba(255, 107, 107, 0.14);
  color: var(--danger);
}

.review-meta {
  display: grid;
  gap: 8px;
  margin: 0 0 14px;
}

.review-meta div {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 10px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 8px;
}

.review-meta dt,
.review-meta dd {
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
  line-height: 1.5;
}

.review-meta dt {
  color: #ff9aaa;
  font-size: 12px;
  font-weight: 700;
}

.review-meta dd {
  color: var(--muted);
  font-size: 12px;
}

.action-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 14px;
}

.action-pill {
  display: grid;
  min-height: 34px;
  place-items: center;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.07);
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  padding: 6px;
}

.action-pill.approve {
  background: rgba(123, 216, 143, 0.14);
  color: var(--ok);
}

.action-pill.reject {
  background: rgba(255, 107, 107, 0.14);
  color: var(--danger);
}

.gate-list {
  display: grid;
  gap: 10px;
  padding: 0;
  margin: 0 0 14px;
  list-style: none;
}

.gate-list li {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.gate-list span {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(233, 75, 115, 0.18);
  color: #ff9aaa;
  font-size: 12px;
  font-weight: 800;
}

.gate-list p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

@media (max-width: 820px) {
  .topbar,
  .hero {
    grid-template-columns: 1fr;
  }

  .topbar {
    align-items: flex-start;
  }

  .nav {
    justify-content: flex-start;
  }

  .grid,
  .status-grid {
    grid-template-columns: 1fr;
  }

  .direction-board {
    order: 1;
    grid-template-columns: 1fr;
  }

  .direction-card.wide {
    grid-column: auto;
  }

  .hero-copy {
    order: 2;
    min-height: auto;
  }

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

  .hero-copy h1 {
    font-size: 28px;
    line-height: 1.16;
  }

  .hero-copy > div:first-child > p:not(.mobile-first-note) {
    display: none;
  }

  .hero-copy .notice {
    margin-top: 10px;
    font-size: 12px;
    line-height: 1.55;
  }

  .mobile-first-note {
    display: block;
    margin-top: 10px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.55;
  }

  .direction-card {
    padding: 12px;
  }

  .phone-frame {
    width: min(100%, 286px);
  }

  .warm-role-card,
  .repository-note {
    font-size: 10px;
  }

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

  .admin-side {
    grid-template-columns: repeat(3, 1fr);
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 0 0 12px;
  }

  .role-workshop-row {
    grid-template-columns: 1fr;
  }

  .flow-board,
  .preference-preview-board,
  .payment-result-board,
  .review-layout,
  .review-meta div,
  .action-grid {
    grid-template-columns: 1fr;
  }

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

  .preview img {
    min-height: 260px;
  }

  .settings-phone-surface {
    padding: 14px;
  }

  .settings-card {
    padding: 14px;
  }

  .setting-row {
    gap: 10px;
    padding: 12px;
  }

  .novel-state-strip {
    grid-template-columns: 1fr;
  }
}
