:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --ink: #f4f8fb;
  --muted: #b8c4cf;
  --line: rgba(148, 163, 184, 0.28);
  --panel: #ffffff;
  --bg: #040b13;
  --accent: #83d51d;
  --accent-strong: #5aab00;
  --gold: #d9e3ea;
  --orange: #86c922;
  --danger: #b42318;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 50% 0%, rgba(126, 211, 33, 0.16), transparent 30%),
    linear-gradient(180deg, #020812 0, #07111d 610px, #eef3f7 611px),
    var(--bg);
  color: var(--ink);
}

a {
  color: #5eb800;
  text-decoration: none;
}

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

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 11px 12px;
  background: #fff;
  color: #0f172a;
}

.prefix-input {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: stretch;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.prefix-input span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 58px;
  padding: 0 13px;
  border-right: 1px solid #d7e1ec;
  background: #eef3f8;
  color: #64748b;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.prefix-input input {
  border: 0;
  border-radius: 0;
}

label {
  display: grid;
  gap: 7px;
  color: #334155;
  font-weight: 700;
  font-size: 13px;
}

.checkline {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 14px;
  font-size: 14px;
  line-height: 1.35;
}

.checkline input {
  width: auto;
  margin-top: 3px;
}

td input[type="checkbox"] {
  width: auto;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 32px;
  background: linear-gradient(180deg, #ffffff, #f3f6f8);
  border-bottom: 1px solid rgba(162, 255, 31, 0.24);
}

.brand {
  color: #07111d;
  font-weight: 900;
  letter-spacing: 0;
}

.topbar nav {
  display: flex;
  gap: 18px;
  font-weight: 700;
}

.shell {
  width: min(1180px, calc(100% - 32px));
  margin: 34px auto 64px;
}

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

.public-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  margin-bottom: 22px;
  padding: 24px 0 8px;
  text-align: center;
}

.hero-copy {
  max-width: 760px;
  margin: 0 auto;
}

.hero-logo {
  width: min(430px, 82vw);
  display: block;
  height: auto;
  margin: 0 auto 18px;
  filter: drop-shadow(0 18px 36px rgba(0, 0, 0, 0.28));
}

.hero-copy h1 {
  max-width: 640px;
  margin: 8px auto 0;
  font-size: 42px;
  line-height: 1.04;
  letter-spacing: 0;
  color: #fff;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.35);
}

.hero-lede {
  max-width: 660px;
  margin: 14px auto 0;
  font-size: 16px;
  line-height: 1.55;
  color: #d9e3ea;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.pay-box {
  display: grid;
  gap: 10px;
  padding: 22px;
  background: linear-gradient(145deg, rgba(8, 16, 28, 0.98), rgba(3, 8, 15, 0.94));
  border: 1px solid rgba(162, 255, 31, 0.34);
  border-radius: 8px;
  box-shadow: 0 18px 40px rgba(0, 8, 20, 0.3);
}

.inline-pay-box {
  margin: 14px 0;
}

.payment-step[hidden] {
  display: none;
}

.optional-label {
  color: #64748b;
  font-weight: 700;
}

.pay-box span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.crypto-panel {
  margin-bottom: 22px;
  padding: 22px;
  border: 1px solid rgba(162, 255, 31, 0.35);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(9, 16, 28, 0.96), rgba(3, 9, 16, 0.94));
  color: #e5f6ff;
  box-shadow: 0 18px 40px rgba(0, 8, 20, 0.18);
}

.crypto-panel h2,
.crypto-panel p {
  color: #e5f6ff;
}

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

.crypto-option {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 14px;
  border: 1px solid rgba(162, 255, 31, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.crypto-copy {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-column: 1 / -1;
  gap: 12px;
  align-items: start;
}

.crypto-option strong {
  display: block;
  color: #b7ff37;
  font-size: 18px;
}

.crypto-option span {
  display: block;
  margin-top: 4px;
  color: #d6e3ea;
  font-size: 13px;
  font-weight: 800;
}

.crypto-option code {
  align-self: center;
  overflow-wrap: anywhere;
  color: #fff;
  font-size: 12px;
  line-height: 1.45;
}

.crypto-qr {
  width: 132px;
  aspect-ratio: 1;
  border: 8px solid #fff;
  border-radius: 8px;
  background: #fff;
}

.pay-box p {
  margin: 0 0 4px;
  font-size: 14px;
  line-height: 1.45;
}

.order-reference-box {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(162, 255, 31, 0.26);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.order-reference-box span {
  grid-column: 1 / -1;
  color: #d6e3ea;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.order-reference-box code {
  overflow-wrap: anywhere;
  color: #fff;
  font-size: 12px;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 18px;
}

.trust-row span {
  border: 1px solid rgba(190, 208, 223, 0.32);
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
}

.trust-row span {
  padding: 8px 10px;
  color: #edf7ff;
  font-size: 13px;
  font-weight: 800;
}

.steps-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: 980px;
  margin: 0 auto 22px;
}

.steps-strip div {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(203, 213, 225, 0.9);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 16px 36px rgba(8, 22, 48, 0.1);
}

.steps-strip strong {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, #d8ff61, #6bbf00);
  color: #07111d;
  font-size: 14px;
}

.steps-strip span {
  color: #1e293b;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.25;
}

.panel-heading {
  margin-bottom: 18px;
}

.panel-heading h2 {
  margin: 0 0 5px;
  font-size: 22px;
}

.panel-heading p {
  margin: 0;
  font-size: 14px;
  line-height: 1.45;
}

.sub-heading {
  margin: 20px 0 14px;
  padding-top: 16px;
  border-top: 1px solid rgba(162, 255, 31, 0.18);
}

.sub-heading h3 {
  margin: 0 0 5px;
  color: #1e293b;
  font-size: 17px;
}

.field-note {
  min-height: 18px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.field-note.is-error {
  color: var(--danger);
}

.order-details {
  margin-bottom: 6px;
}

.page-title {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

h1 {
  margin: 0;
  font-size: 34px;
  line-height: 1.1;
}

p {
  color: var(--muted);
}

.button,
button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 16px;
  background: #fff;
  color: #0f172a;
  cursor: pointer;
  font-weight: 800;
}

.button.primary,
button.primary {
  background: linear-gradient(135deg, #c5f95f, #66bb00);
  border-color: #78bf12;
  color: #07111d;
  box-shadow: 0 10px 22px rgba(91, 171, 0, 0.18);
}

.button:disabled,
button:disabled {
  opacity: 0.5;
  cursor: wait;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.login-panel,
.form-panel,
.preview-panel,
.table-wrap {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
}

.public-shell .form-panel,
.public-shell .preview-panel {
  background: rgba(255, 255, 255, 0.96);
  color: #111827;
  border-color: rgba(203, 213, 225, 0.9);
  box-shadow: 0 18px 44px rgba(8, 22, 48, 0.12);
}

.public-shell .form-panel p,
.public-shell .preview-panel p {
  color: #64748b;
}

.login-panel {
  width: min(430px, 100%);
  margin: 12vh auto;
}

.stack {
  display: grid;
  gap: 16px;
}

.editor-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 430px;
  align-items: start;
  gap: 24px;
}

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

.full-span {
  grid-column: 1 / -1;
}

.airline-admin-panel {
  margin-top: 24px;
}

.canvas-wrap {
  display: grid;
  place-items: center;
}

canvas {
  display: block;
  width: 100%;
  max-width: 390px;
  height: auto;
}

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

th,
td {
  padding: 14px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

td {
  color: #0f172a;
}

th {
  color: #475569;
  font-size: 12px;
  text-transform: uppercase;
}

small {
  color: #64748b;
}

.table-wrap td,
.table-wrap small {
  opacity: 1;
}

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

.empty {
  color: var(--muted);
  text-align: center;
}

.alert,
.notice {
  border-radius: 8px;
  padding: 12px 14px;
}

.alert {
  background: #fef2f2;
  color: var(--danger);
}

.alert p {
  color: var(--danger);
  margin: 0;
}

.notice {
  background: #ecfdf5;
  color: #047857;
}

.legal-note {
  margin: 12px 0 0;
  color: #475569;
  font-size: 13px;
  line-height: 1.45;
}

.delete-form {
  margin-top: 14px;
}

.text-danger {
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--danger);
  min-height: auto;
}

.save-status {
  align-self: center;
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
}

.render-body {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.render-shell {
  display: grid;
  gap: 16px;
  justify-items: center;
  width: min(100%, 980px);
}

.render-shell canvas {
  max-width: min(92vw, 460px);
}

.payment-release-panel {
  width: min(100%, 760px);
  padding: 22px;
  border: 1px solid rgba(162, 255, 31, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  color: #0f172a;
  box-shadow: 0 24px 60px rgba(0, 8, 20, 0.24);
}

.payment-release-panel .panel-heading h2,
.payment-release-panel .panel-heading p {
  color: #0f172a;
}

.payment-release-panel .inline-form,
.reference-form {
  display: grid;
  gap: 12px;
}

.payment-release-panel .pay-box {
  margin-bottom: 14px;
}

@media (max-width: 900px) {
  body {
    background:
      radial-gradient(circle at 50% 0%, rgba(126, 211, 33, 0.14), transparent 34%),
      linear-gradient(180deg, #020812 0, #07111d 520px, #eef3f7 521px),
      var(--bg);
  }

  .public-hero {
    grid-template-columns: 1fr;
    align-items: start;
    padding-top: 18px;
  }

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

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

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

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

  .preview-panel {
    order: -1;
  }
}

@media (max-width: 640px) {
  body {
    background:
      radial-gradient(circle at 50% 0%, rgba(126, 211, 33, 0.14), transparent 38%),
      linear-gradient(180deg, #020812 0, #07111d 575px, #eef3f7 576px),
      var(--bg);
  }

  .public-shell {
    width: min(100% - 22px, 1220px);
    margin: 10px auto 42px;
  }

  .public-hero {
    margin-bottom: 16px;
    padding-top: 14px;
  }

  .hero-logo {
    width: min(300px, 88vw);
    margin: 0 auto 14px;
  }

  .hero-copy h1 {
    max-width: 100%;
    font-size: 29px;
    line-height: 1.12;
    overflow-wrap: anywhere;
  }

  .hero-lede {
    font-size: 15px;
    line-height: 1.45;
  }

  .trust-row {
    gap: 8px;
    margin-top: 14px;
  }

  .trust-row span {
    padding: 7px 9px;
    font-size: 11px;
  }

  .pay-box,
  .crypto-panel,
  .login-panel,
  .form-panel,
  .preview-panel,
  .table-wrap {
    padding: 16px;
  }

  .crypto-option {
    grid-template-columns: 112px minmax(0, 1fr);
  }

  .crypto-qr {
    width: 112px;
    border-width: 6px;
  }

  .pay-box {
    gap: 8px;
  }

  .steps-strip div {
    padding: 12px;
  }

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

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

  .actions {
    flex-direction: column;
  }
}
