:root {
  --radius: 0px;
  --background: #4c263a;
  --foreground: #eee5de;
  --card: #512980;
  --card-foreground: #eee5de;
  --primary: #ffa800;
  --primary-foreground: #1a0d14;
  --secondary: #3a1c2c;
  --secondary-foreground: #eee5de;
  --muted: #3a1c2c;
  --muted-foreground: #c9b6c2;
  --accent: #68dca0;
  --accent-foreground: #1a0d14;
  --destructive: #d8384a;
  --destructive-foreground: #eee5de;
  --border: #000;
  --input: #2a1420;
  --ring: #ffa800;
  --outline: #000;
  --font-pixel: "Press Start 2P", monospace;
  --font-body: "VT323", monospace;
}

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

html {
  scroll-behavior: smooth;
}

body {
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font-body);
  font-size: 1.35rem;
  line-height: 1.25;
  min-height: 100vh;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-pixel);
  line-height: 1.4;
  font-weight: 400;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: none;
  border: 0;
}

img {
  display: block;
  max-width: 100%;
}

img.pixel {
  image-rendering: pixelated;
}

.app {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

.main {
  flex: 1;
}

.font-pixel {
  font-family: var(--font-pixel);
}

.pixel-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-pixel);
  border: 4px solid var(--outline);
  box-shadow: 4px 4px 0 0 var(--outline);
  text-transform: uppercase;
  padding: 0.85rem 1.1rem;
  font-size: 0.75rem;
  transition: transform 50ms, box-shadow 50ms;
}

.pixel-btn:active:not(:disabled) {
  box-shadow: 0 0 0 0 var(--outline);
  transform: translate(4px, 4px);
}

.pixel-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.pixel-btn.full {
  width: 100%;
}

.pixel-box {
  border: 4px solid var(--outline);
  box-shadow: 6px 6px 0 0 var(--outline);
}

.bg-primary {
  background: var(--primary);
  color: var(--primary-foreground);
}

.bg-card {
  background: var(--card);
  color: var(--foreground);
}

.bg-secondary {
  background: var(--secondary);
}

.bg-accent {
  background: var(--accent);
  color: var(--accent-foreground);
}

.text-primary {
  color: var(--primary);
}

.text-accent {
  color: var(--accent);
}

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

.text-destructive {
  color: var(--destructive);
}

.underline {
  text-decoration: underline;
}

header.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 4px solid var(--outline);
  background: var(--card);
}

.header-inner {
  margin: 0 auto;
  max-width: 72rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.brand img {
  width: 2.5rem;
  height: 2.5rem;
  border: 4px solid var(--outline);
}

.brand span {
  font-family: var(--font-pixel);
  font-size: 1rem;
  color: var(--primary);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.icon-btn {
  position: relative;
  display: flex;
  height: 2.75rem;
  width: 2.75rem;
  align-items: center;
  justify-content: center;
  background: var(--card);
  color: var(--foreground);
}

.icon-btn:hover {
  background: var(--primary);
  color: var(--primary-foreground);
}

.icon-btn.soon {
  opacity: 0.6;
}

.icon-btn.soon:hover {
  background: var(--card);
  color: var(--foreground);
}

.soon-tag {
  position: absolute;
  bottom: -0.5rem;
  right: -0.5rem;
  background: var(--primary);
  color: var(--primary-foreground);
  padding: 0 0.25rem;
  font-family: var(--font-pixel);
  font-size: 7px;
}

.menu-wrap {
  position: relative;
}

.menu-btn {
  display: flex;
  height: 2.75rem;
  width: 2.75rem;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  background: var(--primary);
}

.dot {
  display: block;
  height: 0.375rem;
  width: 0.375rem;
  background: var(--primary-foreground);
}

.menu {
  position: absolute;
  right: 0;
  top: 3.5rem;
  width: 12rem;
  background: var(--card);
  z-index: 50;
}

.menu a {
  display: block;
  border-bottom: 4px solid var(--outline);
  padding: 0.75rem 1.25rem;
  font-family: var(--font-pixel);
  font-size: 0.75rem;
}

.menu a:last-child {
  border-bottom: 0;
}

.menu a:hover,
.menu a.active {
  background: var(--primary);
  color: var(--primary-foreground);
}

footer.site-footer {
  border-top: 4px solid var(--outline);
  background: var(--card);
}

.footer-inner {
  margin: 0 auto;
  max-width: 72rem;
  padding: 1.5rem 1rem;
  text-align: center;
  color: var(--muted-foreground);
}

.hero {
  margin: 0 auto;
  max-width: 72rem;
  display: grid;
  align-items: center;
  gap: 2.5rem;
  padding: 3.5rem 1rem;
}

@media (min-width: 768px) {
  .hero {
    grid-template-columns: 1fr 1fr;
  }
}

.chain-pill {
  display: inline-block;
  margin-bottom: 1rem;
  background: var(--accent);
  color: var(--accent-foreground);
  padding: 0.25rem 0.5rem;
  font-family: var(--font-pixel);
  font-size: 10px;
}

.hero h1 {
  font-size: 1.875rem;
  color: var(--primary);
}

@media (min-width: 768px) {
  .hero h1 {
    font-size: 3rem;
  }
}

.hero-copy {
  margin-top: 1.25rem;
  max-width: 28rem;
  font-size: 1.5rem;
}

.hero-actions {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.ape-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.ape-grid img {
  width: 100%;
  aspect-ratio: 1;
}

.stats {
  border-top: 4px solid var(--outline);
  border-bottom: 4px solid var(--outline);
  background: var(--card);
}

.stats-inner {
  margin: 0 auto;
  max-width: 72rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.stat:not(:last-child) {
  border-right: 4px solid var(--outline);
}

.stat {
  padding: 1.25rem;
  text-align: center;
}

.stat .label {
  color: var(--muted-foreground);
}

.stat .value {
  margin-top: 0.25rem;
  font-family: var(--font-pixel);
  font-size: 0.875rem;
  color: var(--primary);
}

.ca-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem 1rem;
  border-top: 4px solid var(--outline);
  padding: 1rem;
}

.ca-strip .label {
  font-family: var(--font-pixel);
  font-size: 10px;
  color: var(--accent);
}

.ca-value,
.ca-inline a {
  font-family: var(--font-pixel);
  font-size: 10px;
  line-height: 1.6;
  color: var(--primary);
  word-break: break-all;
}

.ca-inline {
  min-width: 0;
}

.ca-value:hover,
.ca-inline a:hover {
  text-decoration: underline;
}

.narrow {
  margin: 0 auto;
  max-width: 48rem;
  padding: 3.5rem 1rem;
}

.narrow.tight {
  padding-top: 3rem;
  padding-bottom: 3rem;
}

.page-title {
  font-size: 1.5rem;
  color: var(--primary);
}

.lead {
  margin-top: 0.75rem;
  font-size: 1.5rem;
}

.section-title {
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
  color: var(--primary);
}

.section-intro {
  margin-bottom: 2rem;
}

.roadmap {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.stage {
  background: var(--card);
  padding: 1.25rem;
}

.stage-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.stage-num {
  font-family: var(--font-pixel);
  font-size: 0.75rem;
  color: var(--accent);
}

.stage h3 {
  font-size: 0.875rem;
  color: var(--primary);
}

.badge {
  margin-left: auto;
  display: inline-block;
  border: 2px solid var(--outline);
  padding: 0.125rem 0.5rem;
  font-family: var(--font-pixel);
  font-size: 9px;
}

.badge.done {
  background: var(--accent);
  color: var(--accent-foreground);
}

.badge.ongoing {
  background: var(--primary);
  color: var(--primary-foreground);
}

.badge.soon {
  background: var(--secondary);
  color: var(--muted-foreground);
}

.badge.live {
  background: var(--accent);
  color: var(--accent-foreground);
  border: 0;
  padding: 0.25rem 0.5rem;
  font-size: 10px;
}

.badge.wait {
  background: var(--primary);
  color: var(--primary-foreground);
  border: 0;
  padding: 0.25rem 0.5rem;
  font-size: 10px;
}

.badge.ended {
  background: var(--destructive);
  color: var(--destructive-foreground);
  border: 0;
  padding: 0.25rem 0.5rem;
  font-size: 10px;
}

.stage-body {
  margin-top: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: 1.25rem;
  line-height: 1.625;
}

.stage-body ul,
.about-list,
.token-list,
.token-steps {
  padding-left: 1.25rem;
}

.stage-body li + li,
.about-list li + li,
.token-list li + li,
.token-steps li + li {
  margin-top: 0.25rem;
}

.dyor {
  margin-top: 1.5rem;
  border-top: 4px solid var(--outline);
  padding-top: 1rem;
  font-size: 0.875rem;
  color: var(--muted-foreground);
}

.faq-title {
  margin-bottom: 2rem;
  font-size: 1.25rem;
}

.faq-group + .faq-group {
  margin-top: 2rem;
}

.faq-group h3 {
  margin-bottom: 0.75rem;
  font-family: var(--font-pixel);
  font-size: 0.75rem;
  color: var(--accent);
}

.faq-items {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

details.faq {
  background: var(--card);
  padding: 1rem;
}

details.faq summary {
  cursor: pointer;
  font-family: var(--font-pixel);
  font-size: 0.75rem;
  list-style: none;
}

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

details.faq .answer {
  margin-top: 0.75rem;
}

.about {
  border-top: 4px solid var(--outline);
  background: var(--secondary);
}

.about h3 {
  margin: 0 0 0.5rem;
  font-size: 0.875rem;
  color: var(--primary);
}

.about p {
  margin-bottom: 1rem;
}

.about .mb-8 {
  margin-bottom: 2rem;
}

.collection {
  background: var(--card);
  margin-bottom: 2rem;
}

.row {
  display: flex;
  gap: 1rem;
  border-bottom: 4px solid var(--outline);
  padding: 0.75rem 1rem;
}

.row:last-child {
  border-bottom: 0;
}

.row .k {
  width: 10rem;
  flex-shrink: 0;
  font-family: var(--font-pixel);
  font-size: 10px;
  color: var(--accent);
}

.row .v {
  font-size: 1.25rem;
}

.signoff {
  font-family: var(--font-pixel);
  font-size: 0.75rem;
  color: var(--accent);
}

.check-box,
.phase,
.panel {
  background: var(--card);
  padding: 1.25rem;
}

.check-box {
  margin-top: 2rem;
}

.check-box h2,
.panel h2 {
  font-size: 0.75rem;
}

.field-row {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

@media (min-width: 640px) {
  .field-row {
    flex-direction: row;
  }
}

input.field {
  flex: 1;
  width: 100%;
  border: 4px solid var(--outline);
  background: var(--input);
  padding: 0.5rem 0.75rem;
  font-size: 1.25rem;
  outline: none;
}

input.field:focus {
  border-color: var(--primary);
}

.phases {
  margin-top: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.phase {
  padding: 0;
}

.phase-toggle {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 1.25rem;
  text-align: left;
}

.phase-toggle h2 {
  font-size: 1rem;
}

.phase-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.step {
  border-top: 4px solid var(--outline);
  padding: 1.25rem;
}

.step.locked {
  opacity: 0.4;
}

.step-head {
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.step-n {
  display: flex;
  height: 2rem;
  width: 2rem;
  align-items: center;
  justify-content: center;
  border: 4px solid var(--outline);
  font-family: var(--font-pixel);
  font-size: 10px;
  background: var(--secondary);
}

.step-n.done {
  background: var(--accent);
  color: var(--accent-foreground);
}

.step h3 {
  font-size: 0.75rem;
}

.step-body {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.quote-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  border: 4px solid var(--outline);
  background: var(--secondary);
  padding: 0.5rem;
}

.quote-line span {
  flex: 1;
}

.linkish {
  font-family: var(--font-pixel);
  font-size: 9px;
}

.linkish.primary {
  color: var(--primary);
}

.success-box {
  border-top: 4px solid var(--outline);
  padding: 1.5rem;
  text-align: center;
}

.mint-layout {
  margin: 0 auto;
  max-width: 64rem;
  display: grid;
  gap: 2.5rem;
  padding: 3rem 1rem;
}

@media (min-width: 768px) {
  .mint-layout {
    grid-template-columns: 1fr 1fr;
  }
}

.mint-card {
  background: var(--card);
  padding: 1.5rem;
}

.mint-card h1 {
  font-size: 1.5rem;
  color: var(--primary);
}

.kv {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  font-size: 1.5rem;
}

.kv-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  border-bottom: 4px solid var(--outline);
  padding-bottom: 0.5rem;
}

.kv-row .k {
  color: var(--muted-foreground);
  flex-shrink: 0;
}

.kv-row .v {
  font-family: var(--font-pixel);
  font-size: 0.75rem;
}

.qty {
  margin-top: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.qty .n {
  width: 2.5rem;
  text-align: center;
  font-family: var(--font-pixel);
}

.mint-actions {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.token-page h1 {
  font-size: 1.5rem;
  color: var(--primary);
}

@media (min-width: 768px) {
  .token-page h1 {
    font-size: 1.875rem;
  }
}

.token-page .lead {
  margin-top: 1.25rem;
}

.panel {
  margin-top: 2rem;
}

.panel h2 {
  font-size: 0.875rem;
  color: var(--primary);
}

.panel .body {
  margin-top: 0.75rem;
  font-size: 1.25rem;
}

.tiny-v {
  font-family: var(--font-pixel);
  font-size: 10px;
  line-height: 1.6;
  text-align: right;
  max-width: 58%;
}

.toasts {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 80;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.toast {
  min-width: 16rem;
  max-width: 22rem;
  background: var(--card);
  border: 4px solid var(--outline);
  box-shadow: 6px 6px 0 0 var(--outline);
  padding: 0.85rem 1rem;
  font-size: 1.15rem;
}

.toast.error {
  border-color: var(--destructive);
}

.toast.success {
  border-color: var(--accent);
}

.hidden {
  display: none !important;
}
