/* Combinado — palco. Visual inspirado na energia de palco
   (navy, magenta, roxo, ouro). Nenhum asset oficial. */

:root {
  --bg: #07060e;
  --bg-2: #100b1c;
  --purple: #9b5cff;
  --purple-soft: #c9a0ff;
  --gold: #ffd24a;
  --gold-deep: #f4c430;
  --magenta: #ff2d8a;
  --cyan: #5ce1ff;
  --text: #f7f1ff;
  --ink: #f7f1ff;
  --muted: #b7a8cc;
  --card: rgba(18, 14, 32, 0.78);
  --stroke: rgba(201, 160, 255, 0.22);
  --danger: #ff6b9d;
  --ok: #7dffc3;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  --radius: 22px;
  --tap: 52px;
  --pad: 22px;
  --line: rgba(201, 160, 255, 0.22);
  --accent: #9b5cff;
  --accent-2: #ffd24a;
  --font-display: "Syne", system-ui, sans-serif;
  --font-body: "Nunito", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  background: var(--bg);
}

html, body {
  margin: 0;
  min-height: 100%;
}

body {
  min-height: 100dvh;
  color: var(--text);
  font-family: var(--font-body);
  background:
    radial-gradient(ellipse 55% 38% at 18% -4%, rgba(155, 92, 255, 0.42), transparent 58%),
    radial-gradient(ellipse 50% 34% at 86% -6%, rgba(255, 45, 138, 0.28), transparent 55%),
    radial-gradient(ellipse 60% 40% at 50% 108%, rgba(244, 196, 48, 0.08), transparent 60%),
    var(--bg);
  overflow-x: hidden;
  overflow-y: auto;
}

.honmoon {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 72px;
  pointer-events: none;
  z-index: 40;
}

.honmoon svg {
  width: 100%;
  height: 100%;
  display: block;
  filter: drop-shadow(0 0 10px rgba(92, 225, 255, 0.45))
          drop-shadow(0 6px 18px rgba(255, 210, 74, 0.28));
}

.stage-grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='2'/%3E%3C/filter%3E%3Crect width='80' height='80' filter='url(%23n)' opacity='.55'/%3E%3C/svg%3E");
}

#app {
  position: relative;
  z-index: 3;
  width: min(480px, 100%);
  margin: 0 auto;
  min-height: 100dvh;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 56px 18px 40px;
  background: linear-gradient(180deg, rgba(7, 6, 14, 0.2), rgba(7, 6, 14, 0.55) 28%, rgba(10, 8, 20, 0.72) 100%);
}

@media (min-width: 560px) {
  body { padding: 28px 16px; }
  #app {
    min-height: min(920px, calc(100dvh - 56px));
    border-radius: 36px;
    border: 1px solid var(--stroke);
    box-shadow:
      0 0 0 1px rgba(255, 210, 74, 0.06),
      0 0 80px rgba(155, 92, 255, 0.28),
      0 30px 80px rgba(0, 0, 0, 0.55);
  }
}

main.sheet {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 28px 22px 22px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  overflow: visible;
}

.card {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 20px 18px;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: visible;
  backdrop-filter: blur(10px);
}

.card:has(.wallet) {
  background: transparent;
  border: 0;
  box-shadow: none;
  padding: 0;
  margin-bottom: 8px;
  backdrop-filter: none;
}

h1 {
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--text);
}

h2 {
  margin: 18px 2px 14px;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 8px;
}

p {
  margin: 0 0 20px;
  color: var(--muted);
  line-height: 1.45;
}

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

.actions, .stack { display: grid; gap: 12px; }

a { color: var(--purple-soft); }

.btn, button, a.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  text-decoration: none;
  border-radius: 18px;
  padding: 14px 16px;
  min-height: var(--tap);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 800;
  border: 0;
  cursor: pointer;
  width: 100%;
  color: white;
}

.btn:active:not(:disabled),
button:active:not(:disabled) {
  transform: scale(0.98);
}

.btn.primary, button.primary, a.primary {
  background: linear-gradient(180deg, #ff4ea0, var(--magenta));
  color: #fff;
  box-shadow: 0 10px 24px rgba(255, 45, 138, 0.32);
}

.btn.child {
  background: linear-gradient(180deg, #b57aff, var(--purple));
  color: #fff;
  box-shadow: 0 10px 24px rgba(155, 92, 255, 0.32);
}

button.ghost, .btn.ghost, a.ghost, a.btn.ghost {
  background: transparent;
  border: 1.5px solid rgba(255, 210, 74, 0.45);
  color: var(--gold);
  box-shadow: none;
}

button.danger, .btn.danger {
  background: transparent;
  border: 1.5px solid rgba(255, 45, 138, 0.45);
  color: #ffb3d4;
  box-shadow: none;
}

button.warn, .btn.warn {
  background: rgba(255, 210, 74, 0.12);
  border: 1.5px solid rgba(255, 210, 74, 0.4);
  color: var(--gold);
  box-shadow: none;
}

button.ok, .btn.ok {
  background: linear-gradient(180deg, #8a7dff, #3ec7c9);
  color: #fff;
  box-shadow: 0 10px 24px rgba(92, 225, 255, 0.2);
}

button.small, a.small, .btn.small {
  padding: 8px 12px;
  min-height: 46px;
  border-radius: 14px;
  font-size: 0.9rem;
  width: auto;
}

.btn:disabled, button:disabled, .btn.disabled {
  cursor: not-allowed;
  background: #2a2438;
  color: #7a718c;
  box-shadow: none;
  border: 1px dashed rgba(255, 255, 255, 0.12);
  transform: none;
}

.row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

label {
  display: block;
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--muted);
  margin: 0 0 6px;
}

input, select, textarea {
  width: 100%;
  margin-top: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  border: 1px solid var(--stroke);
  background: rgba(7, 6, 14, 0.7);
  border-radius: 14px;
  padding: 12px 14px;
  color: var(--text);
}

select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--purple-soft) 50%),
                    linear-gradient(135deg, var(--purple-soft) 50%, transparent 50%);
  background-position: calc(100% - 18px) calc(50% - 3px), calc(100% - 12px) calc(50% - 3px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

textarea { min-height: 72px; resize: vertical; }

input:focus, select:focus, textarea:focus {
  outline: 2px solid var(--purple);
  border-color: var(--purple);
}

.field { margin-bottom: 12px; }

header.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

header.top h1 {
  font-size: 1.35rem;
  margin: 0;
  font-family: var(--font-display);
}

header.top .btn,
header.top button,
header.top a.small {
  flex-shrink: 0;
}

.tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 16px;
}

.tabs a {
  text-align: center;
  text-decoration: none;
  padding: 10px;
  min-height: 44px;
  border-radius: 16px;
  background: rgba(155, 92, 255, 0.12);
  border: 1px solid var(--stroke);
  color: var(--muted);
  font-weight: 800;
  font-family: var(--font-body);
  display: flex;
  align-items: center;
  justify-content: center;
}

.tabs a.on {
  background: rgba(155, 92, 255, 0.28);
  color: var(--gold);
  border-color: rgba(255, 210, 74, 0.35);
  box-shadow: 0 0 18px rgba(155, 92, 255, 0.2);
}

.banner {
  border-radius: 14px;
  padding: 10px 12px;
  margin-bottom: 14px;
  font-size: 0.92rem;
  font-weight: 700;
}

.banner.err {
  background: rgba(255, 45, 138, 0.12);
  border: 1px solid rgba(255, 45, 138, 0.35);
  color: var(--danger);
}

.banner.ok {
  background: rgba(125, 255, 195, 0.1);
  border: 1px solid rgba(125, 255, 195, 0.28);
  color: var(--ok);
}

.child-link, .item {
  display: block;
  text-decoration: none;
  color: inherit;
  background: var(--card);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow);
  border-radius: 16px;
  padding: 14px 16px;
  backdrop-filter: blur(10px);
}

.child-link strong, .item strong {
  font-family: var(--font-display);
  font-weight: 800;
  color: var(--text);
}

.item { margin: 0; }

.item .row { margin-top: 10px; }

.wallet {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  text-align: center;
  margin-bottom: 8px;
}

.wallet > div {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 18px;
  padding: 12px 10px 10px;
  backdrop-filter: blur(10px);
}

.wallet > div:nth-child(1) {
  border-color: rgba(255, 210, 74, 0.45);
  box-shadow: 0 0 24px rgba(255, 210, 74, 0.12);
}

.wallet span {
  display: block;
  font-size: 0.68rem;
  color: var(--muted);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.wallet strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--gold);
  margin-top: 2px;
}

.wallet > div:nth-child(3) strong {
  color: var(--purple-soft);
}

.pin {
  font-family: var(--font-display);
  font-size: 2.6rem;
  letter-spacing: 0.18em;
  font-weight: 800;
  text-align: center;
  margin: 8px 0 4px;
  color: var(--gold);
}

.bindurl {
  word-break: break-all;
  font-size: 0.82rem;
  background: rgba(7, 6, 14, 0.7);
  border: 1px solid var(--stroke);
  color: var(--purple-soft);
  padding: 10px;
  border-radius: 10px;
}

canvas.qr {
  display: block;
  margin: 12px auto;
  width: min(320px, 86vw);
  max-width: 100%;
  height: auto;
  background: #fff;
  padding: 12px;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  border-radius: 0;
  position: relative;
  z-index: 3;
  box-shadow: none;
}

#qr-card {
  overflow: visible;
  position: relative;
  z-index: 3;
}

footer.note {
  margin-top: 22px;
  font-size: 0.8rem;
  color: var(--muted);
  text-align: center;
}

.list {
  display: grid;
  gap: 10px;
}

.meta {
  font-size: 0.82rem;
  color: var(--muted);
  margin: 0;
}

hr.sep {
  border: 0;
  border-top: 1px solid var(--stroke);
  margin: 18px 0;
}
