:root {
  color-scheme: dark;
  --bg: #11130f;
  --bg-elevated: #171a15;
  --panel: rgba(28, 31, 25, 0.92);
  --panel-soft: #20241d;
  --panel-strong: #262b21;
  --line: rgba(255, 255, 255, 0.09);
  --line-strong: rgba(226, 184, 50, 0.28);
  --text: #f5f2e9;
  --muted: #aaa99f;
  --muted-2: #777a72;
  --accent: #e2b832;
  --accent-bright: #f2c84b;
  --accent-ink: #19170f;
  --success: #a6d772;
  --danger: #ff8e7d;
  --shadow: 0 32px 80px rgba(0, 0, 0, 0.28);
  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 14px;
  --max-width: 1400px;
  font-family:
    Inter, Pretendard, "Noto Sans KR", "Apple SD Gothic Neo",
    "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  word-break: keep-all;
  min-width: 320px;
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--text);
  background:
    radial-gradient(circle at 10% 10%, rgba(226, 184, 50, 0.08), transparent 30%),
    linear-gradient(180deg, #0f110e 0%, #131610 100%);
}

button,
input,
select {
  font: inherit;
}

button {
  color: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid var(--accent-bright);
  outline-offset: 3px;
}

.ambient {
  position: fixed;
  z-index: -1;
  width: 460px;
  height: 460px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.08;
  pointer-events: none;
}

.ambient-one {
  top: 90px;
  right: -120px;
  background: var(--accent);
}

.ambient-two {
  left: -180px;
  bottom: -180px;
  background: #718d45;
}

.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
  padding: 0 max(28px, calc((100vw - var(--max-width)) / 2));
  border-bottom: 1px solid var(--line);
  background: rgba(15, 17, 14, 0.86);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  gap: 12px;
  align-items: center;
  color: var(--text);
  text-decoration: none;
}

.brand-name {
  font-weight: 780;
  letter-spacing: -0.035em;
  font-size: 21px;
}

.brand-logo {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
}

.brand-logo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.header-nav {
  display: flex;
  gap: 8px;
}

.nav-button,
.primary-button,
.secondary-button,
.google-button,
.back-link {
  border: 0;
  cursor: pointer;
}

.nav-button {
  padding: 10px 14px;
  color: var(--muted);
  background: transparent;
  border-radius: 12px;
  transition: 160ms ease;
}

.nav-button:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}

.nav-button-strong {
  color: var(--text);
  border: 1px solid var(--line);
}


.view {
  display: none;
}

.view.is-active {
  display: block;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.72fr);
  gap: clamp(48px, 6vw, 96px);
  align-items: center;
  width: min(var(--max-width), calc(100% - 56px));
  min-height: 720px;
  margin: 0 auto;
  padding: 80px 0 66px;
}

.hero-copy {
  max-width: 780px;
}

.eyebrow {
  display: block;
  margin: 0 0 18px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.19em;
  color: var(--accent);
}

.hero h1,
.workflow-page-head h1 {
  text-wrap: balance;
  margin: 0;
  font-size: clamp(48px, 5vw, 76px);
  line-height: 1.04;
  letter-spacing: -0.065em;
}

.hero h1 span {
  color: var(--accent-bright);
}

.hero-description {
  max-width: 720px;
  text-wrap: pretty;
  margin: 28px 0 0;
  color: #bdbbb2;
  font-size: 18px;
  line-height: 1.8;
  letter-spacing: -0.02em;
}

.hero-actions {
  display: flex;
  gap: 12px;
  margin-top: 36px;
}

.primary-button,
.secondary-button,
.google-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 14px;
  font-weight: 750;
  transition:
    transform 160ms ease,
    background 160ms ease,
    border 160ms ease;
}

.primary-button {
  color: var(--accent-ink);
  background: var(--accent-bright);
  box-shadow: 0 12px 36px rgba(226, 184, 50, 0.12);
}

.primary-button:hover {
  transform: translateY(-1px);
  background: #f7d45d;
}

.secondary-button,
.google-button {
  color: var(--text);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
}

.secondary-button:hover,
.google-button:hover {
  background: rgba(255, 255, 255, 0.065);
  border-color: rgba(255, 255, 255, 0.16);
}

.primary-button:disabled,
.secondary-button:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  transform: none;
}

.full-button {
  width: 100%;
}

.benefit-stack {
  display: grid;
  gap: 16px;
  width: 100%;
  max-width: 430px;
  justify-self: end;
  align-self: center;
}

.benefit {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  min-height: 104px;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.018);
}

.benefit-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  font-size: 12px;
  font-weight: 850;
  color: var(--accent);
  border-radius: 13px;
  background: rgba(226, 184, 50, 0.1);
}

.benefit strong,
.benefit span {
  display: block;
}

.benefit strong {
  font-size: 16px;
  line-height: 1.35;
}

.benefit div > span {
  margin-top: 7px;
  font-size: 12px;
  line-height: 1.55;
  color: var(--muted);
}

.status-chip {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  font-size: 10px;
  font-weight: 800;
  color: var(--success);
  border-radius: 999px;
  background: rgba(166, 215, 114, 0.09);
  border: 1px solid rgba(166, 215, 114, 0.13);
}

.category-symbol {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  font-size: 18px;
  font-weight: 900;
  color: var(--accent);
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: rgba(226, 184, 50, 0.075);
}

.builder-shell {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr) 300px;
  width: min(1540px, calc(100% - 40px));
  min-height: calc(100vh - 112px);
  margin: 0 auto;
  padding: 34px 0 50px;
}

.builder-sidebar {
  padding: 20px 28px 20px 10px;
  border-right: 1px solid var(--line);
}

.back-link {
  padding: 0;
  font-size: 12px;
  color: var(--muted);
  background: transparent;
}

.back-link:hover {
  color: var(--text);
}

.builder-heading {
  margin-top: 44px;
}

.builder-heading .eyebrow {
  margin-bottom: 12px;
}

.builder-heading h2 {
  margin: 0;
  font-size: 28px;
  letter-spacing: -0.045em;
}

.builder-heading p {
  margin: 8px 0 0;
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
}

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

.step-item {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 11px;
  align-items: center;
  min-height: 62px;
  padding: 10px;
  color: var(--muted-2);
  border-radius: 14px;
  transition: 160ms ease;
}

.step-item > span {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  font-size: 11px;
  font-weight: 800;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.step-item strong,
.step-item small {
  display: block;
}

.step-item strong {
  font-size: 12px;
}

.step-item small {
  margin-top: 3px;
  font-size: 10px;
  color: inherit;
}

.step-item.is-active {
  color: var(--text);
  background: rgba(226, 184, 50, 0.075);
}

.step-item.is-active > span {
  color: var(--accent);
  border-color: var(--line-strong);
}

.step-item.is-complete {
  color: #b7b5ac;
}

.step-item.is-complete > span {
  color: var(--success);
}

.builder-main {
  min-width: 0;
  padding: 20px 44px 30px;
}

.builder-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 44px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.step-counter {
  display: inline-flex;
  min-width: 44px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 800;
}

.step-title {
  font-size: 13px;
  font-weight: 700;
}

.draft-state {
  font-size: 10px;
  color: var(--muted-2);
}

.builder-stage {
  min-height: 570px;
}

.builder-panel {
  display: none;
  padding: 44px 0 22px;
}

.builder-panel.is-active {
  display: block;
  animation: panel-in 180ms ease;
}

@keyframes panel-in {
  from {
    opacity: 0;
    transform: translateY(7px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.panel-heading {
  max-width: 760px;
}

.panel-kicker {
  display: block;
  margin-bottom: 14px;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.17em;
  color: var(--accent);
}

.panel-heading h2 {
  margin: 0;
  text-wrap: balance;
  font-size: clamp(30px, 3.2vw, 44px);
  letter-spacing: -0.055em;
}

.panel-heading p {
  max-width: 700px;
  margin: 16px 0 0;
  line-height: 1.75;
  color: var(--muted);
}

.form-card,
.module-card,
.final-summary {
  margin-top: 32px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--panel);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

[data-category-retry][hidden] {
  display: none;
}

.category-picker-status {
  margin: 28px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.category-picker-status.is-error {
  color: var(--danger);
}

.category-picker {
  min-width: 0;
  padding: 0;
  margin: 18px 0;
  border: 0;
}

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

.category-choice {
  position: relative;
  display: block;
  cursor: pointer;
}

.category-choice > input {
  position: absolute;
  top: 24px;
  right: 24px;
  z-index: 1;
  width: 19px;
  height: 19px;
  margin: 0;
  accent-color: var(--accent-bright);
  cursor: pointer;
}

.category-choice-body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 252px;
  height: 100%;
  padding: 24px;
  gap: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--panel);
  transition: border-color 160ms ease, background 160ms ease;
}

.category-choice:hover .category-choice-body {
  border-color: var(--line-strong);
}

.category-choice > input:checked + .category-choice-body {
  border-color: var(--accent);
  background: rgba(226, 184, 50, 0.065);
}

.category-choice > input:focus-visible + .category-choice-body {
  outline: 2px solid var(--accent-bright);
  outline-offset: 4px;
}

.category-choice-name {
  font-size: 23px;
  letter-spacing: -0.04em;
}

.category-choice-description {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.8;
}

.category-choice-state {
  margin-top: auto;
  color: var(--muted-2);
  font-size: 11px;
}

.category-choice > input:checked + .category-choice-body .category-choice-state {
  color: var(--accent-bright);
}

.category-selection-note {
  font-size: 12px;
  line-height: 1.7;
  color: var(--muted);
}

.base-field-preview {
  margin-top: 28px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.018);
}

.base-field-preview h3 {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
}

.base-field-preview .field-grid {
  margin-top: 14px;
}

.live-category-empty {
  margin-top: 18px;
  font-size: 13px;
  line-height: 1.8;
  color: var(--muted);
}

[data-live-category-content] > p {
  margin: 8px 0 20px;
  font-size: 10px;
  line-height: 1.6;
  color: var(--muted);
}

@media (max-width: 600px) {
  .category-choice-grid {
    grid-template-columns: 1fr;
  }

  .category-choice-body {
    min-height: 226px;
  }
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
  margin-top: 24px;
}

.field-pill {
  display: grid;
  grid-template-columns: 25px 1fr auto;
  gap: 8px;
  align-items: center;
  min-height: 50px;
  padding: 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.025);
}

.field-pill > span {
  font-size: 9px;
  font-weight: 800;
  color: var(--accent);
}

.field-pill strong {
  font-size: 12px;
}

.field-pill small {
  font-size: 9px;
  color: var(--muted-2);
}

.form-card {
  display: grid;
  gap: 24px;
}

.form-field {
  display: grid;
  gap: 9px;
  margin: 0;
  padding: 0;
  border: 0;
}

.form-field > span,
.form-field > legend {
  padding: 0;
  font-size: 12px;
  font-weight: 720;
  color: #d8d6ce;
}

.form-field input,
.form-field select,
.inline-config input,
.inline-config select {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
  outline: none;
}

.form-field input:focus,
.form-field select:focus,
.inline-config input:focus,
.inline-config select:focus {
  border-color: rgba(226, 184, 50, 0.56);
  box-shadow: 0 0 0 3px rgba(226, 184, 50, 0.07);
}

.form-field small {
  color: var(--muted-2);
  font-size: 10px;
  line-height: 1.55;
}


.auth-display-name[hidden],
[data-auth-password-confirm-field][hidden] {
  display: none !important;
}

.password-input-wrap {
  position: relative;
}

.password-input-wrap input {
  padding-right: 66px;
}

.password-visibility {
  position: absolute;
  top: 50%;
  right: 8px;
  min-width: 48px;
  height: 32px;
  padding: 0 8px;
  transform: translateY(-50%);
  cursor: pointer;
  color: var(--muted);
  font-size: 10px;
  font-weight: 720;
  border: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.password-visibility:hover,
.password-visibility:focus-visible {
  color: var(--text);
  background: rgba(226, 184, 50, 0.09);
  outline: none;
}

.password-requirements {
  position: absolute;
  left: 0;
  top: calc(100% + 10px);
  z-index: 20;
  width: min(270px, calc(100vw - 64px));
  padding: 13px 14px;
  color: var(--text);
  border: 1px solid rgba(226, 184, 50, 0.2);
  border-radius: 12px;
  background: rgba(20, 23, 18, 0.98);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.34);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity 140ms ease, transform 140ms ease, visibility 140ms ease;
}

.password-requirements::before {
  content: "";
  position: absolute;
  top: -6px;
  left: 22px;
  width: 10px;
  height: 10px;
  border-top: 1px solid rgba(226, 184, 50, 0.2);
  border-left: 1px solid rgba(226, 184, 50, 0.2);
  background: rgba(20, 23, 18, 0.98);
  transform: rotate(45deg);
}

.password-input-wrap:focus-within .password-requirements:not([hidden]) {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.password-requirements strong {
  display: block;
  margin-bottom: 8px;
  font-size: 10px;
  letter-spacing: 0.02em;
}

.password-requirements ul {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.password-requirements li {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--muted-2);
  font-size: 10px;
  line-height: 1.35;
}

.password-requirements li > span {
  display: inline-grid;
  place-items: center;
  flex: 0 0 16px;
  width: 16px;
  height: 16px;
  color: var(--muted-2);
  border: 1px solid var(--line);
  border-radius: 50%;
  font-size: 9px;
  font-weight: 800;
}

.password-requirements li.is-met {
  color: var(--text);
}

.password-requirements li.is-met > span {
  color: #d9ff9b;
  border-color: rgba(161, 216, 93, 0.35);
  background: rgba(161, 216, 93, 0.09);
}

.segmented-control {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  max-width: 460px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.02);
}

.segmented-control button {
  min-height: 38px;
  color: var(--muted);
  cursor: pointer;
  border: 0;
  border-radius: 9px;
  background: transparent;
}

.segmented-control button.is-selected {
  color: var(--text);
  background: rgba(226, 184, 50, 0.12);
  box-shadow: inset 0 0 0 1px rgba(226, 184, 50, 0.15);
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 32px;
}

.module-card {
  margin-top: 0;
  transition: 160ms ease;
}

.module-card:not(.is-selected) {
  opacity: 0.55;
}

.module-card.is-selected {
  border-color: var(--line-strong);
  background:
    linear-gradient(180deg, rgba(226, 184, 50, 0.055), rgba(255, 255, 255, 0.018));
}

.module-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.module-index {
  display: block;
  margin-bottom: 9px;
  font-size: 9px;
  font-weight: 850;
  color: var(--accent);
}

.module-head h3 {
  margin: 0;
  font-size: 20px;
  letter-spacing: -0.035em;
}

.module-card > p {
  min-height: 52px;
  margin: 14px 0 20px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--muted);
}

.toggle {
  position: relative;
  width: 42px;
  height: 24px;
  padding: 0;
  cursor: pointer;
  border: 0;
  border-radius: 999px;
  background: #41453e;
}

.toggle span {
  position: absolute;
  top: 4px;
  left: 4px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #d7d8d2;
  transition: 160ms ease;
}

.toggle.is-on {
  background: var(--accent);
}

.toggle.is-on span {
  left: 22px;
  background: var(--accent-ink);
}

.inline-config {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 10px;
  align-items: center;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.inline-config span {
  font-size: 10px;
  color: var(--muted);
}

.inline-config input,
.inline-config select {
  min-height: 38px;
  font-size: 12px;
}

.finish-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 14px;
}

.final-summary {
  align-self: start;
}

.summary-label {
  display: block;
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 0.15em;
  color: var(--accent);
}

.final-summary h3,
.live-summary h3 {
  margin: 10px 0 0;
  font-size: 22px;
  letter-spacing: -0.035em;
}

.final-summary dl {
  display: grid;
  gap: 0;
  margin: 24px 0;
}

.final-summary dl > div {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.final-summary dt,
.final-summary dd {
  margin: 0;
  font-size: 11px;
}

.final-summary dt {
  color: var(--muted);
}

.summary-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 22px;
}

.summary-tags span {
  padding: 7px 9px;
  font-size: 10px;
  color: #d5d1c1;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

.preview-note {
  padding: 15px;
  border-radius: 14px;
  background: rgba(226, 184, 50, 0.06);
  border: 1px solid rgba(226, 184, 50, 0.1);
}

.preview-note strong {
  display: block;
  font-size: 11px;
  color: var(--accent);
}

.preview-note p {
  margin: 7px 0 0;
  font-size: 11px;
  line-height: 1.65;
  color: var(--muted);
}

.save-workflow-control {
  display: grid;
  grid-template-columns: auto auto 1fr;
  gap: 10px;
  align-items: center;
  padding: 14px;
  cursor: pointer;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
}

.save-workflow-control > input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.save-workflow-switch {
  position: relative;
  width: 42px;
  height: 24px;
  border-radius: 999px;
  background: #41453e;
  transition: 160ms ease;
}

.save-workflow-switch::after {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #d7d8d2;
  transition: 160ms ease;
}

.save-workflow-control > input:checked + .save-workflow-switch {
  background: var(--accent);
}

.save-workflow-control > input:checked + .save-workflow-switch::after {
  left: 22px;
  background: var(--accent-ink);
}

.save-workflow-control > span:last-child strong,
.save-workflow-control > span:last-child small {
  display: block;
}

.save-workflow-control > span:last-child strong { font-size: 12px; }
.save-workflow-control > span:last-child small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.form-field.is-disabled { opacity: 0.42; }

.final-action-note {
  display: block;
  margin-top: 10px;
  text-align: center;
  color: var(--muted-2);
  font-size: 9px;
  line-height: 1.5;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.018);
}

.auth-tabs button {
  min-height: 38px;
  cursor: pointer;
  color: var(--muted);
  border: 0;
  border-radius: 9px;
  background: transparent;
}

.auth-tabs button.is-active {
  color: var(--text);
  background: rgba(226, 184, 50, 0.11);
  box-shadow: inset 0 0 0 1px rgba(226, 184, 50, 0.14);
}

.builder-actions {
  display: flex;
  justify-content: space-between;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.live-summary {
  padding: 20px 10px 20px 28px;
  border-left: 1px solid var(--line);
}

.live-summary > p {
  margin: 8px 0 20px;
  font-size: 10px;
  line-height: 1.6;
  color: var(--muted);
}

.live-sheet {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
}

.live-sheet-head {
  display: flex;
  gap: 9px;
  align-items: center;
  padding: 12px;
  border-bottom: 1px solid var(--line);
}

.live-sheet-head > span {
  display: grid;
  place-items: center;
  width: 29px;
  height: 29px;
  font-size: 8px;
  font-weight: 900;
  color: var(--accent-ink);
  border-radius: 7px;
  background: var(--accent);
}

.live-sheet-head strong {
  font-size: 11px;
}

.sheet-column-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

.sheet-column-row span {
  overflow: hidden;
  padding: 9px 7px;
  font-size: 8px;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: #bdbbb3;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.sheet-column-row span:last-child {
  border-right: 0;
}

.sheet-column-row.muted span {
  color: var(--muted-2);
}

.live-module-list {
  display: grid;
  gap: 7px;
  margin-top: 14px;
}

.live-module-list > div {
  display: flex;
  justify-content: space-between;
  padding: 10px 11px;
  font-size: 9px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.025);
}

.live-module-list strong {
  color: var(--success);
  font-size: 8px;
}

.live-module-list div.is-off strong {
  color: var(--muted-2);
}

.workflow-page {
  width: min(1180px, calc(100% - 56px));
  margin: 0 auto;
  padding: 74px 0 110px;
}

.workflow-page-head {
  display: flex;
  gap: 40px;
  align-items: flex-end;
  justify-content: space-between;
}

.workflow-page-head h1 {
  margin-top: 8px;
  font-size: clamp(42px, 4.5vw, 64px);
}

.workflow-page-head p {
  max-width: 650px;
  margin: 18px 0 0;
  line-height: 1.75;
  color: var(--muted);
}

.workflow-page-head .back-link {
  margin-bottom: 46px;
}

.workflow-empty {
  display: grid;
  place-items: center;
  margin-top: 56px;
  padding: 76px 28px;
  text-align: center;
  border: 1px dashed rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.018);
}

.workflow-empty.is-hidden {
  display: none;
}

.empty-symbol {
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  color: var(--accent);
  border-radius: 16px;
  background: rgba(226, 184, 50, 0.09);
}

.workflow-empty h2 {
  margin: 20px 0 8px;
  font-size: 20px;
}

.workflow-empty p {
  max-width: 520px;
  margin: 0 0 22px;
  line-height: 1.7;
  color: var(--muted);
}

.workflow-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 56px;
}

.workflow-preview-card {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--panel);
}

.workflow-preview-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.workflow-preview-card h3 {
  margin: 7px 0 0;
  font-size: 20px;
}

.workflow-preview-card p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 11px;
}

.workflow-preview-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 20px 0;
}

.workflow-preview-card-tags span {
  padding: 6px 8px;
  font-size: 9px;
  border-radius: 999px;
  background: rgba(226, 184, 50, 0.08);
  color: #d8ca96;
}

.workflow-card-actions {
  display: flex;
  gap: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.workflow-card-actions button {
  min-height: 38px;
  padding: 0 12px;
  cursor: pointer;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
}

.workflow-card-actions button:first-child {
  flex: 1;
  color: var(--accent-ink);
  background: var(--accent);
  border-color: var(--accent);
  font-weight: 750;
}

.login-dialog {
  width: min(460px, calc(100% - 32px));
  padding: 0;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #1a1d18;
  box-shadow: var(--shadow);
}

.login-dialog::backdrop {
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(8px);
}

.login-card {
  position: relative;
  display: grid;
  gap: 16px;
  padding: 30px;
}

.login-card h2 {
  margin: -4px 0 0;
  font-size: 28px;
  letter-spacing: -0.045em;
}

.login-card > p {
  margin: -5px 0 10px;
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted);
}

.dialog-close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  cursor: pointer;
  color: var(--muted);
  border: 0;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.035);
}

.login-divider {
  position: relative;
  height: 20px;
  text-align: center;
}

.login-divider::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--line);
}

.login-divider span {
  position: relative;
  padding: 0 10px;
  font-size: 9px;
  color: var(--muted-2);
  background: #1a1d18;
}

.google-g {
  font-weight: 900;
  color: #e0ded6;
}

.toast {
  position: fixed;
  z-index: 50;
  right: 24px;
  bottom: 24px;
  max-width: 380px;
  padding: 14px 16px;
  color: var(--text);
  font-size: 12px;
  line-height: 1.5;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: #25291f;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(14px);
  pointer-events: none;
  transition: 180ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: none;
}

@media (max-width: 1180px) {
  .hero {
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 36px;
  }

  .builder-shell {
    grid-template-columns: 210px minmax(0, 1fr);
  }

  .live-summary {
    display: none;
  }
}

@media (max-width: 900px) {
  .site-header {
    padding-inline: 20px;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    width: min(100% - 40px, 760px);
    padding-top: 60px;
  }

  .benefit-stack {
    max-width: none;
    justify-self: stretch;
    margin-top: 8px;
  }

  .field-grid,
  .module-grid,
  .finish-grid,
  .workflow-list {
    grid-template-columns: 1fr;
  }

  .workflow-page {
    width: min(100% - 40px, 760px);
  }

  .builder-shell {
    display: block;
    width: min(100% - 28px, 760px);
  }

  .builder-sidebar {
    padding: 18px 0;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .builder-heading {
    margin-top: 24px;
  }

  .step-list {
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
    overflow-x: auto;
  }

  .step-item {
    grid-template-columns: 30px 1fr;
    min-width: 145px;
  }

  .builder-main {
    padding: 20px 0 30px;
  }

  .workflow-page-head {
    display: grid;
    align-items: start;
  }

  .workflow-page-head .back-link {
    margin-bottom: 30px;
  }
}

@media (max-width: 600px) {
  .site-header {
    min-height: 64px;
  }

  .brand-name {
    font-size: 18px;
  }

  .header-nav .nav-button:first-child {
    display: none;
  }

  .hero {
    width: calc(100% - 28px);
    padding-top: 42px;
  }

  .hero h1 {
    font-size: 43px;
  }

  .hero-description {
    font-size: 15px;
  }

  .hero-actions {
    display: grid;
  }

  .benefit-stack {
    gap: 10px;
  }

  .benefit {
    grid-template-columns: 42px minmax(0, 1fr);
    min-height: 88px;
    padding: 16px;
  }

  .benefit-icon {
    width: 42px;
    height: 42px;
  }

  .workflow-page {
    width: calc(100% - 28px);
  }

  .panel-heading h2 {
    font-size: 32px;
  }

  .form-card,
  .module-card,
  .final-summary {
    padding: 18px;
  }

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

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

  .draft-state {
    max-width: 120px;
    text-align: right;
  }

  .inline-config {
    grid-template-columns: 1fr;
  }

  .workflow-page {
    padding-top: 46px;
  }

  .toast {
    right: 14px;
    bottom: 14px;
    left: 14px;
    max-width: none;
  }
}

.auth-user {
  max-width: 180px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: var(--muted);
  font-size: 12px;
}

.auth-api-note {
  margin: -10px 0 0;
  color: var(--muted-2);
  font-size: 9px;
}

.auth-error {
  margin: 0;
  padding: 10px 12px;
  color: #ffb6aa;
  font-size: 11px;
  line-height: 1.5;
  border: 1px solid rgba(255, 142, 125, 0.18);
  border-radius: 11px;
  background: rgba(255, 142, 125, 0.06);
}

.is-busy {
  cursor: wait !important;
  opacity: 0.62 !important;
  pointer-events: none;
}

.workflow-card-actions {
  flex-wrap: wrap;
}
