:root {
  --bg: #08111f;
  --panel: rgba(11, 22, 39, 0.82);
  --panel-strong: rgba(15, 30, 54, 0.94);
  --line: rgba(140, 188, 255, 0.2);
  --text: #eef6ff;
  --muted: #8ea4be;
  --cyan: #45f3ff;
  --green: #4dffbc;
  --blue: #4d76ff;
  --orange: #ffbd66;
  --red: #ff6b8a;
  --shadow: 0 30px 80px rgba(0, 0, 0, 0.44);
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  font-family: "Rajdhani", "HarmonyOS Sans SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at 15% 10%, rgba(69, 243, 255, 0.24), transparent 28rem),
    radial-gradient(circle at 90% 12%, rgba(77, 118, 255, 0.25), transparent 30rem),
    linear-gradient(135deg, #07101d 0%, #0a1628 42%, #101a2b 100%);
}

body::before {
  position: fixed;
  inset: 0;
  pointer-events: none;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent 78%);
}

button,
input {
  font: inherit;
}

button {
  border: 0;
}

.shell {
  display: grid;
  min-height: 100vh;
  padding: 32px 16px;
  place-items: center;
}

.hero-card {
  position: relative;
  width: min(100%, 760px);
  overflow: hidden;
  padding: 36px;
  border: 1px solid var(--line);
  border-radius: 34px;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.09), transparent 38%),
    var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px);
}

.hero-card::after {
  position: absolute;
  inset: 1px;
  z-index: -1;
  border-radius: 33px;
  content: "";
  background: linear-gradient(135deg, rgba(69, 243, 255, 0.28), transparent 40%, rgba(77, 255, 188, 0.14));
}

.orb {
  position: absolute;
  width: 260px;
  height: 260px;
  border-radius: 999px;
  filter: blur(5px);
  opacity: 0.42;
}

.orb-a {
  top: -140px;
  right: -70px;
  background: radial-gradient(circle, rgba(69, 243, 255, 0.8), transparent 65%);
}

.orb-b {
  bottom: -170px;
  left: -80px;
  background: radial-gradient(circle, rgba(77, 255, 188, 0.55), transparent 67%);
}

.topline {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 9px 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: rgba(4, 12, 24, 0.45);
}

.signal-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 22px var(--green);
}

.headline {
  position: relative;
  margin-top: 34px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--cyan);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.22em;
}

h1 {
  max-width: 620px;
  margin: 0;
  font-size: clamp(38px, 7vw, 66px);
  line-height: 1.04;
  letter-spacing: -0.05em;
}

.subcopy {
  max-width: 620px;
  margin: 18px 0 0;
  color: #b6c7dc;
  font-size: 17px;
  line-height: 1.75;
}

.route-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 30px;
}

.info-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 24px;
}

.info-strip div {
  padding: 15px 16px;
  border: 1px solid rgba(77, 255, 188, 0.22);
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(77, 255, 188, 0.12), rgba(69, 243, 255, 0.05));
}

.info-strip span {
  display: block;
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.info-strip strong {
  display: block;
  margin-top: 7px;
  color: #eafff7;
  font-size: 15px;
  line-height: 1.55;
}

.risk-panel {
  margin-top: 14px;
  border: 1px solid rgba(255, 107, 138, 0.38);
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(255, 107, 138, 0.16), rgba(255, 189, 102, 0.06)),
    rgba(3, 10, 20, 0.5);
  box-shadow: 0 18px 48px rgba(255, 107, 138, 0.1);
}

.risk-panel summary {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  cursor: pointer;
  list-style: none;
}

.risk-panel summary::-webkit-details-marker {
  display: none;
}

.risk-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  color: #23040b;
  font-size: 13px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--red), var(--orange));
}

.risk-panel summary strong {
  flex: 1;
  color: #fff4f6;
  font-size: 18px;
  letter-spacing: 0.02em;
}

.risk-chevron {
  color: var(--orange);
  font-size: 13px;
  font-weight: 800;
}

.risk-panel[open] .risk-chevron {
  color: var(--green);
}

.risk-content {
  padding: 0 18px 18px;
  color: #ffdfe5;
  font-size: 15px;
  line-height: 1.75;
}

.risk-content p {
  margin: 10px 0 0;
}

.route-item,
.number-box,
.code-box {
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(3, 10, 20, 0.42);
}

.route-item {
  padding: 17px;
}

.route-item span,
.field-label,
label {
  display: block;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.route-item strong {
  display: block;
  margin-top: 7px;
  font-size: 19px;
}

.start-form {
  margin-top: 30px;
}

.input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  margin-top: 10px;
}

input {
  width: 100%;
  min-height: 58px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  outline: none;
  color: var(--text);
  letter-spacing: 0.06em;
  background: rgba(3, 10, 20, 0.6);
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

input:focus {
  border-color: rgba(69, 243, 255, 0.75);
  box-shadow: 0 0 0 4px rgba(69, 243, 255, 0.12);
}

button {
  min-height: 48px;
  padding: 0 20px;
  border-radius: 16px;
  color: #03101d;
  font-weight: 800;
  letter-spacing: 0.03em;
  background: linear-gradient(135deg, var(--cyan), var(--green));
  box-shadow: 0 18px 40px rgba(69, 243, 255, 0.18);
  cursor: pointer;
  transition: transform 160ms ease, opacity 160ms ease, box-shadow 160ms ease;
}

button:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 22px 52px rgba(69, 243, 255, 0.24);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.secondary-button {
  color: var(--text);
  background: linear-gradient(135deg, rgba(77, 118, 255, 0.8), rgba(69, 243, 255, 0.24));
}

.ghost-button {
  border: 1px solid var(--line);
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  box-shadow: none;
}

.notice {
  min-height: 22px;
  margin-top: 16px;
  color: var(--orange);
  font-size: 15px;
}

.notice.success {
  color: var(--green);
}

.notice.error {
  color: var(--red);
}

.order-panel {
  margin-top: 22px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--panel-strong);
}

.hidden {
  display: none;
}

.status-row,
.copy-row,
.actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  color: #04111f;
  font-weight: 800;
  background: var(--orange);
}

.status-pill.active {
  background: var(--cyan);
}

.status-pill.ready {
  background: var(--green);
}

.status-pill.error {
  color: var(--text);
  background: var(--red);
}

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

.small {
  margin: 14px 0 0;
  font-size: 14px;
}

.number-box,
.code-box {
  margin-top: 14px;
  padding: 16px;
}

.copy-row strong {
  overflow-wrap: anywhere;
  font-size: clamp(26px, 5vw, 42px);
  letter-spacing: 0.04em;
}

.code-value {
  margin-top: 9px;
  color: var(--green);
  font-size: clamp(30px, 7vw, 58px);
  font-weight: 900;
  letter-spacing: 0.14em;
}

.progress {
  height: 4px;
  overflow: hidden;
  margin-top: 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.progress-bar {
  width: 32%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--cyan), var(--green));
  animation: scan 1.6s ease-in-out infinite alternate;
}

.actions {
  margin-top: 18px;
}

@keyframes scan {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(210%);
  }
}

@media (max-width: 680px) {
  .hero-card {
    padding: 24px;
    border-radius: 26px;
  }

  .route-grid,
  .info-strip,
  .input-row {
    grid-template-columns: 1fr;
  }

  .actions,
  .status-row {
    align-items: stretch;
    flex-direction: column;
  }

  .actions button,
  .input-row button {
    width: 100%;
  }
}
