.tokenize-page-shell {
  --tokenize-shadow: 0 24px 80px rgba(0, 0, 0, 0.26);
}

.tokenize-app-hero {
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  background:
    radial-gradient(circle at top right, rgba(74, 222, 128, 0.1), transparent 36%),
    linear-gradient(180deg, rgba(17, 17, 17, 0.98), rgba(12, 12, 12, 0.98));
  padding: 38px 40px 34px;
  box-shadow: var(--tokenize-shadow);
  overflow: hidden;
  position: relative;
}

.tokenize-app-hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--green-border) 48%, transparent 100%);
}

.tokenize-app-hero-copy {
  margin-bottom: 26px;
}

.tokenize-app-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.96fr) minmax(0, 1.04fr);
  gap: 18px;
}

.tokenize-card {
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 28px;
  display: grid;
  gap: 18px;
  min-width: 0;
}

.tokenize-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.tokenize-card-head .section-title {
  margin: 0;
}

.tokenize-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 11px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--green-border);
  background: var(--green-dim);
  color: var(--green);
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

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

.tokenize-field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.tokenize-field-compact {
  grid-column: span 2;
  max-width: 220px;
}

.tokenize-fee-field {
  grid-column: span 2;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--bg);
  padding: 16px;
  gap: 10px;
}

.tokenize-field-label {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tokenize-field-note {
  font-family: var(--body);
  font-size: 0.76rem;
  line-height: 1.45;
  color: var(--text-muted);
}

.tokenize-fee-head,
.tokenize-fee-scale {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tokenize-fee-percent {
  font-family: var(--sans);
  font-size: 1.2rem;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--green);
}

.tokenize-range {
  width: 100%;
  appearance: none;
  height: 8px;
  border-radius: 999px;
  border: 0;
  background: linear-gradient(90deg, rgba(74, 222, 128, 0.18), rgba(74, 222, 128, 0.8));
  outline: none;
}

.tokenize-range::-webkit-slider-thumb {
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #f5f5f5;
  border: 2px solid #062c14;
  box-shadow: 0 0 0 4px rgba(74, 222, 128, 0.18);
  cursor: pointer;
}

.tokenize-range::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #f5f5f5;
  border: 2px solid #062c14;
  box-shadow: 0 0 0 4px rgba(74, 222, 128, 0.18);
  cursor: pointer;
}

.tokenize-fee-scale {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--text-dim);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.tokenize-fee-note {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.55;
  color: var(--text-muted);
}

.tokenize-network-panel {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--bg);
}

.tokenize-network-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.tokenize-network-head strong {
  display: block;
  font-family: var(--sans);
  font-size: 1rem;
}

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

.tokenize-network-button {
  appearance: none;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 11px 10px;
  cursor: pointer;
  transition: border-color 140ms ease, background 140ms ease, color 140ms ease, transform 140ms ease;
}

.tokenize-network-button:hover {
  border-color: var(--green-border);
  color: var(--green);
  background: var(--green-dim);
}

.tokenize-network-button.is-active {
  border-color: rgba(96, 165, 250, 0.4);
  background: rgba(59, 130, 246, 0.12);
  color: #8ebcff;
}

.tokenize-input {
  width: 100%;
  min-width: 0;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  padding: 11px 12px;
  font-family: var(--mono);
  font-size: 0.82rem;
  outline: none;
  transition: border-color 140ms ease, box-shadow 140ms ease, background 140ms ease;
}

.tokenize-input::placeholder {
  color: var(--text-dim);
}

.tokenize-input:focus {
  border-color: var(--green-border);
  box-shadow: 0 0 0 3px var(--green-dim);
}

.tokenize-input:disabled {
  cursor: wait;
  opacity: 0.7;
}

.tokenize-preview-panel,
.tokenize-workflow-card,
.tokenize-launch-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--bg);
  padding: 16px;
}

.tokenize-source-meta {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  border-radius: var(--radius-lg);
  border: 1px solid var(--green-border);
  background: linear-gradient(180deg, rgba(74, 222, 128, 0.08), rgba(74, 222, 128, 0.03));
  padding: 16px;
}

.tokenize-source-media {
  width: 88px;
  height: 68px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg);
}

.tokenize-source-thumb {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tokenize-source-copy {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.tokenize-source-copy strong {
  display: block;
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.25;
}

.tokenize-source-copy p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.55;
}

.tokenize-source-link {
  width: fit-content;
  color: var(--green);
  text-decoration: none;
  font-family: var(--mono);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.tokenize-source-link:hover {
  color: #85f7b2;
}

.tokenize-builder-codes-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background:
    radial-gradient(circle at top left, rgba(74, 222, 128, 0.09), transparent 42%),
    linear-gradient(180deg, rgba(18, 18, 18, 0.98), rgba(10, 10, 10, 0.98));
  padding: 16px;
  display: grid;
  gap: 12px;
}

.tokenize-builder-codes-head,
.tokenize-builder-meta {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.tokenize-builder-code,
.tokenize-builder-pill,
.tokenize-builder-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  font-family: var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tokenize-builder-code {
  min-width: 58px;
  padding: 10px 12px;
  border: 1px solid var(--green-border);
  background: var(--green-dim);
  color: var(--green);
  font-size: 0.92rem;
  font-weight: 700;
}

.tokenize-builder-summary,
.tokenize-builder-reason {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.55;
}

.tokenize-builder-summary {
  font-size: 0.9rem;
}

.tokenize-builder-meta {
  justify-content: flex-start;
}

.tokenize-builder-pill,
.tokenize-builder-chip {
  padding: 7px 10px;
  border: 1px solid var(--border);
  background: var(--surface-hover);
  color: var(--text-muted);
  font-size: 0.66rem;
  font-weight: 600;
}

.tokenize-builder-chip {
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  min-width: 0;
  white-space: normal;
}

.tokenize-builder-chip strong {
  font-size: 0.78rem;
  color: var(--text);
  letter-spacing: 0.04em;
}

.tokenize-builder-chip span {
  font-size: 0.62rem;
}

.tokenize-builder-stack {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.tokenize-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.tokenize-preview-head strong {
  font-family: var(--sans);
  font-size: 0.98rem;
}

.tokenize-ghost-button,
.tokenize-quick,
.tokenize-action,
.tokenize-launch-link {
  appearance: none;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface-hover);
  color: var(--text);
  font-family: var(--mono);
  cursor: pointer;
  transition: border-color 140ms ease, background 140ms ease, color 140ms ease, transform 140ms ease;
}

.tokenize-ghost-button {
  padding: 8px 12px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.tokenize-ghost-button:hover,
.tokenize-quick:hover,
.tokenize-action:hover,
.tokenize-launch-link:hover {
  border-color: var(--green-border);
  background: var(--green-dim);
  color: var(--green);
}

.tokenize-preview-stack {
  display: grid;
  gap: 8px;
}

.tokenize-preview-row {
  display: grid;
  gap: 6px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
}

@media (max-width: 760px) {
  .tokenize-builder-stack {
    grid-template-columns: 1fr;
  }

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

.tokenize-preview-row span {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.tokenize-preview-row code {
  font-size: 0.76rem;
  color: var(--text);
}

.tokenize-action-row,
.tokenize-quick-row,
.tokenize-launch-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tokenize-action {
  padding: 11px 14px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.tokenize-action-primary,
.tokenize-send {
  background: var(--green);
  border-color: transparent;
  color: #062c14;
}

.tokenize-action-primary:hover,
.tokenize-send:hover {
  background: #5bf198;
  color: #062c14;
  transform: translateY(-1px);
}

.tokenize-quick {
  padding: 8px 12px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.tokenize-step-tag {
  display: inline-flex;
  width: fit-content;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--green-border);
  background: var(--green-dim);
  color: var(--green);
  font-family: var(--mono);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 8px;
}

.tokenize-workflow-card strong,
.tokenize-launch-meta strong {
  display: block;
  font-family: var(--sans);
  font-size: 1rem;
  margin-bottom: 8px;
}

.tokenize-workflow-card p,
.tokenize-launch-meta p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.55;
}

.tokenize-console-card {
  align-content: start;
}

.tokenize-status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 11px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface-hover);
  color: var(--text-muted);
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-align: center;
}

.tokenize-status-pill[data-tone="live"] {
  border-color: var(--green-border);
  background: var(--green-dim);
  color: var(--green);
}

.tokenize-status-pill[data-tone="warning"] {
  border-color: var(--orange-dim);
  background: rgba(251, 146, 60, 0.12);
  color: var(--orange);
}

.tokenize-status-pill[data-tone="ready"] {
  border-color: var(--blue-border);
  background: var(--blue-dim);
  color: var(--blue);
}

.tokenize-launch-card {
  display: grid;
  gap: 12px;
}

.tokenize-launch-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
}

.tokenize-launch-link-secondary {
  color: var(--text-muted);
}

.tokenize-thread {
  display: grid;
  gap: 10px;
  padding: 2px;
  min-height: 280px;
  max-height: 620px;
  overflow-y: auto;
}

.tokenize-thread-empty {
  border-radius: var(--radius-lg);
  border: 1px dashed var(--border);
  background: rgba(255, 255, 255, 0.015);
  padding: 18px;
  color: var(--text-muted);
  line-height: 1.6;
}

.tokenize-message {
  display: flex;
}

.tokenize-message-user {
  justify-content: flex-end;
}

.tokenize-message-bot {
  justify-content: flex-start;
}

.tokenize-bubble {
  max-width: 88%;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface-hover);
  padding: 12px 14px;
  color: var(--text);
  line-height: 1.55;
  font-size: 0.92rem;
  overflow-wrap: anywhere;
}

.tokenize-message-user .tokenize-bubble {
  background: var(--green-dim);
  border-color: var(--green-border);
}

.tokenize-message-bot .tokenize-bubble strong {
  color: var(--green);
}

.tokenize-bubble a {
  color: var(--green);
  text-decoration: underline;
  text-decoration-color: var(--green-border);
  text-underline-offset: 2px;
}

.tokenize-bubble[data-pending="true"] {
  color: var(--text-muted);
}

.tokenize-composer {
  display: flex;
  gap: 10px;
  padding-top: 2px;
}

.tokenize-send {
  border-radius: var(--radius-sm);
  padding: 0 18px;
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 0;
  white-space: nowrap;
  cursor: pointer;
}

.tokenize-send:disabled,
.tokenize-action:disabled,
.tokenize-quick:disabled,
.tokenize-ghost-button:disabled {
  opacity: 0.6;
  cursor: wait;
  transform: none;
}

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

.tokenize-info-card {
  min-height: 100%;
}

.tokenize-advanced-shell {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--bg);
  padding: 14px 16px 16px;
}

.tokenize-advanced-shell summary {
  list-style: none;
  cursor: pointer;
  font-family: var(--mono);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
}

.tokenize-advanced-shell summary::-webkit-details-marker {
  display: none;
}

.tokenize-advanced-copy {
  margin: 12px 0 14px;
  color: var(--text-muted);
  line-height: 1.55;
  font-size: 0.9rem;
}

@media (max-width: 1180px) {
  .tokenize-app-grid,
  .tokenize-info-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .tokenize-app-hero,
  .tokenize-card {
    padding: 22px 18px;
    border-radius: var(--radius-lg);
  }

  .tokenize-card-head,
  .tokenize-preview-head {
    flex-direction: column;
    align-items: flex-start;
  }

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

  .tokenize-field-compact {
    grid-column: auto;
    max-width: none;
  }

  .tokenize-fee-field {
    grid-column: auto;
  }

  .tokenize-thread {
    min-height: 260px;
  }

  .tokenize-source-meta {
    grid-template-columns: 1fr;
  }

  .tokenize-source-media {
    width: 100%;
    height: 180px;
  }

  .tokenize-composer {
    flex-direction: column;
  }

  .tokenize-send {
    width: 100%;
    padding: 12px 16px;
  }
}
