:root {
  color-scheme: light;
  --ink: #071111;
  --muted: #526160;
  --paper: #f7f4ec;
  --paper-strong: #fffaf0;
  --teal: #00c7b1;
  --teal-dark: #048b80;
  --coral: #ff6b4a;
  --line: rgba(7, 17, 17, 0.14);
  --shadow: 0 28px 80px rgba(7, 17, 17, 0.16);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(7, 17, 17, 0.045) 1px, transparent 1px),
    linear-gradient(rgba(7, 17, 17, 0.04) 1px, transparent 1px),
    var(--paper);
  background-size: 36px 36px;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  width: 100%;
  margin: 0;
  padding: 12px max(16px, calc((100vw - 1160px) / 2));
  border-bottom: 1px solid rgba(7, 17, 17, 0.1);
  background: rgba(247, 244, 236, 0.94);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  width: auto;
  min-width: 0;
}

.brand-logo,
.dex-logo,
.mako-ball img {
  display: block;
  width: 100%;
  height: auto;
}

.brand-logo {
  width: auto;
  height: 38px;
  max-width: 220px;
  aspect-ratio: 1500 / 390;
  object-fit: contain;
}

.nav {
  display: flex;
  align-items: center;
  gap: 18px;
  color: rgba(7, 17, 17, 0.74);
  font-size: 0.88rem;
  font-weight: 750;
  white-space: nowrap;
}

.nav a {
  border-bottom: 2px solid transparent;
}

.nav a:hover,
.nav a:focus-visible,
.nav a[aria-current="page"] {
  border-color: var(--teal-dark);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(330px, 0.78fr);
  gap: clamp(28px, 5vw, 78px);
  align-items: center;
  width: min(1160px, calc(100% - 32px));
  min-height: calc(100vh - 78px);
  margin: 0 auto;
  padding: 34px 0 64px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--teal-dark);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 790px;
  margin-bottom: 22px;
  font-size: clamp(3.6rem, 10vw, 7.65rem);
  line-height: 0.9;
  letter-spacing: 0;
}

h2 {
  max-width: 740px;
  margin-bottom: 16px;
  font-size: clamp(2.1rem, 5.2vw, 4.6rem);
  line-height: 0.94;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 8px;
  font-size: 1.05rem;
}

p {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.6;
}

.hero-text {
  max-width: 650px;
  font-size: clamp(1.05rem, 2.1vw, 1.28rem);
}

.hero-actions,
.signup-form {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  font-weight: 900;
  box-shadow: 4px 4px 0 var(--ink);
  transition:
    transform 160ms ease,
    box-shadow 160ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--ink);
}

.primary {
  color: var(--ink);
  background: var(--teal);
}

.secondary {
  background: var(--paper-strong);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  max-width: 520px;
  margin: 36px 0 0;
}

.hero-stats div,
.steps article,
.rarity,
.signup {
  border: 2px solid var(--ink);
  background: rgba(255, 250, 240, 0.82);
}

.hero-stats div {
  padding: 15px 14px;
}

.hero-stats dt {
  font-size: 1.4rem;
  font-weight: 950;
}

.hero-stats dd {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.hero-visual {
  display: grid;
  place-items: center;
}

.machine-panel {
  width: min(420px, 100%);
  padding: 18px;
  border: 3px solid var(--ink);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(0, 199, 177, 0.16), transparent 48%),
    #101818;
  box-shadow: var(--shadow);
}

.machine-top,
.machine-controls {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.machine-top span {
  padding: 7px 10px;
  border: 2px solid rgba(255, 250, 240, 0.22);
  border-radius: 999px;
  color: #fffaf0;
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.display {
  display: grid;
  gap: 18px;
  place-items: center;
  min-height: 455px;
  margin: 16px 0;
  padding: 26px;
  border: 2px solid rgba(255, 250, 240, 0.2);
  border-radius: 6px;
  background:
    radial-gradient(circle at 50% 38%, rgba(0, 199, 177, 0.34), transparent 33%),
    #071111;
}

.mako-ball {
  position: relative;
  display: grid;
  place-items: center;
  width: min(250px, 70vw);
  aspect-ratio: 1;
  border: 5px solid #fffaf0;
  border-radius: 50%;
  background:
    linear-gradient(140deg, rgba(255, 255, 255, 0.2), transparent 36%),
    var(--teal);
}

.mako-ball::before,
.mako-ball::after {
  position: absolute;
  content: "";
}

.mako-ball::before {
  top: 13%;
  left: 17%;
  width: 34%;
  height: 18%;
  border-radius: 50%;
  background: rgba(255, 250, 240, 0.28);
  filter: blur(2px);
  transform: rotate(-22deg);
}

.mako-ball::after {
  top: 21%;
  right: 22%;
  width: 14px;
  height: 14px;
  box-shadow:
    -34px 26px 0 #071111,
    22px 42px 0 var(--coral),
    -8px 72px 0 #fffaf0;
}

.mako-m {
  z-index: 1;
  color: #fffaf0;
  font-size: 6.8rem;
  font-weight: 950;
  line-height: 1;
  text-shadow:
    5px 5px 0 #071111,
    0 0 18px rgba(7, 17, 17, 0.18);
}

.orbit {
  position: absolute;
  border: 2px solid rgba(255, 250, 240, 0.72);
  border-radius: 50%;
}

.orbit-one {
  inset: 22px;
  transform: rotate(-18deg) scaleY(0.38);
}

.orbit-two {
  inset: 45px;
  border-color: rgba(7, 17, 17, 0.7);
  transform: rotate(32deg) scaleY(0.5);
}

.display-copy {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 2px solid rgba(255, 250, 240, 0.18);
  border-radius: 999px;
}

.display-copy p {
  margin: 0;
  color: #fffaf0;
  font-size: 0.9rem;
  font-weight: 750;
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--coral);
  box-shadow: 0 0 0 6px rgba(255, 107, 74, 0.18);
}

.machine-controls span {
  display: block;
  width: 30%;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 250, 240, 0.22);
}

.section {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
  padding: 78px 0;
}

.section-heading {
  margin-bottom: 26px;
}

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

.steps article {
  min-height: 220px;
  padding: 22px;
}

.step-number {
  display: block;
  margin-bottom: 48px;
  color: var(--coral);
  font-size: 0.88rem;
  font-weight: 950;
}

.drop {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(320px, 1fr);
  gap: 28px;
  align-items: end;
}

.drop-copy p {
  max-width: 540px;
}

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

.rarity {
  min-height: 210px;
  padding: 20px;
}

.rarity span {
  display: block;
  margin-bottom: 64px;
  font-size: 3.2rem;
  font-weight: 950;
  line-height: 1;
}

.rarity h3 {
  margin: 0;
}

.common {
  background: #fffaf0;
}

.rare {
  background: var(--teal);
}

.glitch {
  color: #fffaf0;
  background: #071111;
}

.signup {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(300px, 1fr);
  gap: 26px;
  align-items: end;
  margin-bottom: 70px;
  padding: clamp(24px, 5vw, 44px);
}

.signup h2 {
  font-size: clamp(2rem, 4.4vw, 3.8rem);
}

.signup-form {
  align-items: end;
}

.signup-form label {
  display: grid;
  flex: 1 1 260px;
  gap: 8px;
  color: var(--ink);
  font-size: 0.86rem;
  font-weight: 850;
}

.signup-form input {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  color: var(--ink);
  background: var(--paper-strong);
  font: inherit;
  font-weight: 750;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0 34px;
  color: rgba(7, 17, 17, 0.68);
  font-size: 0.86rem;
  font-weight: 800;
}

.pets-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(320px, 0.75fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
  width: min(1160px, calc(100% - 32px));
  min-height: calc(72vh - 78px);
  margin: 0 auto;
  padding: 46px 0 54px;
}

.pets-title h1 {
  max-width: 760px;
  margin-bottom: 18px;
  font-size: clamp(3.4rem, 9vw, 7rem);
}

.pets-title p {
  max-width: 620px;
  font-size: clamp(1.05rem, 2vw, 1.24rem);
}

.dex-panel {
  overflow: hidden;
  border: 3px solid var(--ink);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 107, 74, 0.18), transparent 46%),
    var(--paper-strong);
  box-shadow: var(--shadow);
}

.dex-logo {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  padding: 28px;
  border-bottom: 3px solid var(--ink);
  background: #fff;
}

.dex-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin: 0;
}

.dex-stats div {
  min-width: 0;
  padding: 16px 14px;
}

.dex-stats div + div {
  border-left: 2px solid var(--ink);
}

.dex-stats dt {
  font-size: 1.45rem;
  font-weight: 950;
}

.dex-stats dd {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 780;
}

.pets-toolbar,
.pets-grid,
.pets-cta {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
}

.pets-toolbar {
  position: sticky;
  top: 76px;
  z-index: 9;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 12px 0 18px;
  backdrop-filter: blur(18px);
}

.chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--paper-strong);
  font-size: 0.85rem;
  font-weight: 900;
}

.chip.active,
.chip:hover,
.chip:focus-visible {
  background: var(--teal);
}

.pets-page:has(#comuns:target) .chip.active,
.pets-page:has(#raros:target) .chip.active,
.pets-page:has(#glitch:target) .chip.active {
  background: var(--paper-strong);
}

.pets-page:has(#comuns:target) .chip[href="#comuns"],
.pets-page:has(#raros:target) .chip[href="#raros"],
.pets-page:has(#glitch:target) .chip[href="#glitch"] {
  background: var(--teal);
}

.target-anchor {
  position: relative;
  top: -120px;
  display: block;
  width: min(1160px, calc(100% - 32px));
  height: 0;
  margin: 0 auto;
  overflow: hidden;
}

.pets-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  padding: 26px 0 80px;
}

#comuns:target ~ .pets-grid .pet-card:not(.common-pet),
#raros:target ~ .pets-grid .pet-card:not(.rare-pet),
#glitch:target ~ .pets-grid .pet-card:not(.glitch-pet) {
  display: none;
}

.pet-card {
  display: grid;
  min-height: 420px;
  padding: 18px;
  border: 2px solid var(--ink);
  background: rgba(255, 250, 240, 0.88);
}

.pet-avatar {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 1.18;
  margin-bottom: 16px;
  overflow: hidden;
  border: 2px solid var(--ink);
  border-radius: 8px;
  background: var(--teal);
}

.pet-avatar::before {
  position: absolute;
  inset: 18%;
  content: "";
  border: 4px solid var(--ink);
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 36%, #fffaf0 0 7px, transparent 8px),
    radial-gradient(circle at 66% 36%, #fffaf0 0 7px, transparent 8px),
    rgba(255, 250, 240, 0.25);
  box-shadow: inset -16px -18px 0 rgba(7, 17, 17, 0.12);
}

.pet-avatar::after {
  position: absolute;
  bottom: 29%;
  width: 24%;
  height: 9%;
  content: "";
  border-radius: 999px;
  background: var(--ink);
}

.pet-face {
  position: absolute;
  top: 23%;
  left: 50%;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--ink);
  box-shadow:
    -34px 34px 0 var(--ink),
    34px 34px 0 var(--ink),
    0 76px 0 var(--coral);
  transform: translateX(-50%);
}

.aqua {
  background: var(--teal);
}

.coral {
  background: var(--coral);
}

.lemon {
  background: #ffd84d;
}

.violet {
  background: #9e7cff;
}

.moss {
  background: #7ccf8b;
}

.void {
  background:
    linear-gradient(135deg, rgba(255, 107, 74, 0.3), transparent 46%),
    #071111;
}

.void::before {
  border-color: #fffaf0;
  background:
    radial-gradient(circle at 34% 36%, var(--coral) 0 7px, transparent 8px),
    radial-gradient(circle at 66% 36%, var(--teal) 0 7px, transparent 8px),
    rgba(255, 250, 240, 0.08);
}

.void::after,
.void .pet-face {
  background: #fffaf0;
}

.void .pet-face {
  box-shadow:
    -34px 34px 0 #fffaf0,
    34px 34px 0 #fffaf0,
    0 76px 0 var(--coral);
}

.pet-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
  font-size: 0.8rem;
  font-weight: 950;
  text-transform: uppercase;
}

.pet-number {
  color: var(--coral);
}

.pet-rarity {
  padding: 6px 9px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--paper-strong);
}

.pet-card h2 {
  margin-bottom: 8px;
  font-size: clamp(1.55rem, 3vw, 2.2rem);
  line-height: 1;
}

.pet-card p {
  margin-bottom: 20px;
}

.pet-element {
  align-self: end;
  color: var(--ink);
  font-size: 0.86rem;
  font-weight: 900;
}

.rare-pet {
  background: rgba(0, 199, 177, 0.24);
}

.glitch-pet {
  color: #fffaf0;
  background: #071111;
}

.glitch-pet p,
.glitch-pet .pet-element {
  color: rgba(255, 250, 240, 0.78);
}

.glitch-pet .pet-rarity {
  color: var(--ink);
}

.pets-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 42px 0 76px;
  border-top: 2px solid var(--line);
}

.pets-cta h2 {
  margin-bottom: 0;
  font-size: clamp(2rem, 4.5vw, 3.9rem);
}

@media (max-width: 860px) {
  .site-header {
    min-height: 58px;
    padding: 10px 12px;
  }

  .brand {
    width: auto;
  }

  .brand-logo {
    height: 32px;
    max-width: 170px;
  }

  .nav {
    display: none;
  }

  .hero,
  .pets-hero,
  .drop,
  .signup {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-top: 32px;
  }

  .display {
    min-height: 330px;
  }

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

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

  .pets-cta {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 560px) {
  .site-header,
  .hero,
  .pets-hero,
  .pets-toolbar,
  .pets-grid,
  .pets-cta,
  .section,
  .footer {
    width: min(100% - 24px, 1160px);
  }

  .hero-stats,
  .steps,
  .rarity-grid,
  .pets-grid {
    grid-template-columns: 1fr;
  }

  .dex-stats {
    grid-template-columns: 1fr;
  }

  .dex-stats div + div {
    border-top: 2px solid var(--ink);
    border-left: 0;
  }

  .hero-stats div,
  .steps article,
  .rarity {
    min-height: auto;
  }

  .step-number,
  .rarity span {
    margin-bottom: 28px;
  }

  .footer {
    flex-direction: column;
  }
}
