:root {
  --cream: #f5e8d3;
  --knit: #efe0c4;
  --knit-dark: #e2cfab;
  --orange: #f2895e;
  --pink: #ec8fa2;
  --mustard: #f4c430;
  --plum: #6e4f7f;
  --ink: #1a1a1a;
  --muted: #7a7268;
  --outline: 4px solid var(--ink);
  --sticker-edge: 0 0 0 7px #fffaf0, 0 0 0 10px var(--ink);
  --display: 'Bagel Fat One', 'Arial Rounded MT Bold', sans-serif;
  --hand: 'Gaegu', 'Comic Sans MS', cursive;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  font-family: var(--hand);
  font-size: 22px;
  line-height: 1.35;
  background: var(--cream);
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }

/* the sunset behind everything, drifting very slowly */
.sky {
  position: fixed; inset: -20% -20% -20% -20%; z-index: -2;
  background: linear-gradient(170deg, #f7b58a 0%, var(--orange) 30%, var(--pink) 62%, #b787a8 100%);
  animation: drift 40s ease-in-out infinite alternate;
}
@keyframes drift { from { transform: translate3d(0, 0, 0) rotate(0deg); } to { transform: translate3d(-4%, 3%, 0) rotate(3deg); } }

/* sleeping z's floating up */
.zzz { position: fixed; inset: 0; pointer-events: none; z-index: -1; }
.zzz span {
  position: absolute; bottom: -60px; font-family: var(--display); color: rgba(255, 250, 240, .55);
  animation: rise 22s linear infinite; font-size: 42px;
}
.zzz span:nth-child(1) { left: 8%; animation-delay: 0s; }
.zzz span:nth-child(2) { left: 26%; animation-delay: -6s; font-size: 70px; }
.zzz span:nth-child(3) { left: 48%; animation-delay: -12s; }
.zzz span:nth-child(4) { left: 67%; animation-delay: -3s; font-size: 60px; }
.zzz span:nth-child(5) { left: 84%; animation-delay: -15s; }
.zzz span:nth-child(6) { left: 93%; animation-delay: -9s; font-size: 30px; }
@keyframes rise {
  0% { transform: translate3d(0, 0, 0) rotate(-10deg); opacity: 0; }
  10% { opacity: 1; }
  100% { transform: translate3d(40px, -115vh, 0) rotate(12deg); opacity: 0; }
}

/* every element is a die-cut sticker slapped onto the blanket */
.stk {
  transform: rotate(var(--r, 0deg));
  box-shadow: var(--sticker-edge), 6px 10px 0 10px rgba(26, 26, 26, .18);
}
.slap { opacity: 0; transform: rotate(var(--r, 0deg)) scale(1.35) translateY(-18px); transition: transform .45s cubic-bezier(.2, 1.6, .4, 1), opacity .25s ease; }
.slap.in { opacity: 1; transform: rotate(var(--r, 0deg)) scale(1); }

/* top: stickers along the door frame */
.door {
  display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
  padding: 24px clamp(18px, 4vw, 48px) 0;
}
.brand-sticker {
  display: inline-flex; align-items: center; gap: 10px; padding: 6px 16px 6px 6px; text-decoration: none;
  background: var(--mustard); border-radius: 999px; font-family: var(--display); font-size: 28px;
}
.brand-sticker img { width: 48px; height: 48px; border-radius: 50%; border: 3px solid var(--ink); }
.tabs { display: flex; gap: 22px; flex-wrap: wrap; }
.tab {
  display: inline-block; padding: 4px 16px; background: #fffaf0; border-radius: 14px; text-decoration: none; font-weight: 700;
  transition: transform .2s ease;
}
.tab:hover, .tab:focus-visible { transform: rotate(0deg) translateY(-3px) scale(1.06); }
.tab:active { transform: rotate(0deg) scale(.96); }

/* hero: a door hanger, a giant sticker and a wordmark slapped across it */
.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  grid-template-areas: "hanger art" "word art" "tag art" "links art";
  column-gap: clamp(24px, 5vw, 80px);
  align-items: start;
  max-width: 1320px; margin: 0 auto; padding: 40px clamp(18px, 4vw, 48px) 80px;
}
.hanger {
  grid-area: hanger; justify-self: start; position: relative; width: 250px; padding: 76px 22px 26px;
  background: var(--plum); color: #fffaf0; border-radius: 30px 30px 22px 22px; text-align: center;
  transform-origin: 50% 0; animation: sway 7s ease-in-out infinite;
}
@keyframes sway { 0%, 100% { transform: rotate(var(--r)); } 50% { transform: rotate(calc(var(--r) + 3deg)); } }
.hanger-hole {
  position: absolute; top: 16px; left: 50%; width: 64px; height: 44px; margin-left: -32px;
  background: var(--cream); border: var(--outline); border-radius: 50%;
}
.hanger-kicker { margin: 0; font-size: 26px; }
.hanger-big { margin: 4px 0 8px; font-family: var(--display); font-size: 58px; line-height: .92; color: var(--mustard); }
.hanger-small { margin: 0; font-size: 20px; opacity: .9; }

.hero-art {
  grid-area: art; border-radius: 42% 46% 40% 44% / 44% 40% 46% 42%; overflow: hidden; background: var(--orange);
  margin-top: 10px;
}
.hero-art img { width: 100%; aspect-ratio: 1; object-fit: cover; }

.wordmark { grid-area: word; margin: 40px 0 0; font-family: var(--display); font-weight: 400; font-size: clamp(76px, 11vw, 168px); line-height: 1; display: flex; }
.wm-q, .wm-rest { display: inline-block; padding: 0 .12em .06em; border-radius: .22em; }
.wm-q { background: var(--mustard); position: relative; z-index: 1; }
.wm-rest { background: #fffaf0; margin-left: -.08em; }
.ticker {
  grid-area: tag; justify-self: start; margin: 34px 0 0; padding: 4px 20px; background: var(--ink); color: var(--mustard);
  font-family: var(--display); font-size: 34px; border-radius: 12px;
}
.tagline {
  grid-area: tag; justify-self: start; margin: 110px 0 0 30px; padding: 6px 20px; background: var(--pink);
  font-size: 32px; font-weight: 700; border-radius: 16px;
}
.hero-links { grid-area: links; display: flex; gap: 22px; margin-top: 40px; flex-wrap: wrap; }

.sticker-btn {
  display: inline-flex; align-items: center; gap: 10px; padding: 10px 22px; background: var(--mustard); border-radius: 18px;
  font-family: var(--display); font-size: 24px; text-decoration: none; color: var(--ink);
  transition: transform .18s ease, box-shadow .18s ease;
}
.sticker-btn svg { width: 26px; height: 26px; }
.sticker-btn.alt { background: #fffaf0; }
.sticker-btn:hover, .sticker-btn:focus-visible { transform: rotate(0deg) translateY(-4px) scale(1.05); box-shadow: var(--sticker-edge), 8px 16px 0 10px rgba(26, 26, 26, .2); }
.sticker-btn:active { transform: rotate(0deg) scale(.95); box-shadow: var(--sticker-edge), 2px 3px 0 10px rgba(26, 26, 26, .2); }

/* sections sit on the knit blanket */
.spelling, .status, .tuck {
  position: relative; padding: 90px clamp(18px, 4vw, 48px);
  background-color: var(--knit);
  background-image:
    repeating-linear-gradient(90deg, rgba(150, 118, 78, .13) 0 3px, transparent 3px 56px),
    linear-gradient(58deg, transparent 44%, rgba(150, 118, 78, .16) 48%, rgba(255, 250, 238, .55) 52%, transparent 56%),
    linear-gradient(-58deg, transparent 44%, rgba(150, 118, 78, .16) 48%, rgba(255, 250, 238, .55) 52%, transparent 56%);
  background-size: 56px 100%, 28px 22px, 28px 22px;
  border-top: var(--outline);
}
.spelling::before, .status::before, .tuck::before {
  content: ""; position: absolute; left: 0; right: 0; top: -18px; height: 18px;
  background: radial-gradient(circle at 12px 18px, var(--knit) 11px, var(--ink) 12px, var(--ink) 14px, transparent 15px) 0 0 / 24px 18px repeat-x;
}
.sheet-title {
  display: table; margin: 0 auto 60px; padding: 8px 28px; background: var(--orange); color: #fffaf0;
  font-family: var(--display); font-weight: 400; font-size: clamp(34px, 5vw, 58px); border-radius: 20px;
  text-shadow: 3px 3px 0 var(--ink);
}

.sheet { position: relative; max-width: 1100px; margin: 0 auto; display: grid; gap: 56px; }
.word-row { display: grid; grid-template-columns: auto auto auto 1fr; align-items: center; gap: 22px 30px; }
.word {
  padding: 10px 26px; background: #fffaf0; border-radius: 22px; font-family: var(--display); font-size: clamp(44px, 6vw, 84px); line-height: 1;
}
.word s { text-decoration-thickness: 8px; text-decoration-color: var(--orange); color: var(--muted); }
.word-qu b { font-weight: 400; background: var(--mustard); border-radius: 12px; padding: 0 6px; }
.word-us { background: var(--pink); }
.arrow { font-family: var(--display); font-size: 58px; color: var(--plum); }
.note { margin: 0; font-size: 24px; max-width: 30ch; }
.patch {
  position: absolute; left: -40px; top: -90px; width: 120px; height: 120px; display: grid; place-items: center;
  background: var(--mustard); border-radius: 50%; font-family: var(--display); font-size: 54px;
}
.story {
  max-width: 44ch; margin: 80px auto 0; padding: 26px 32px; background: #fffaf0; border: var(--outline); border-radius: 26px 8px 26px 8px;
  font-size: 28px; transform: rotate(-1deg);
}
.story em { font-style: normal; font-weight: 700; background: linear-gradient(transparent 60%, var(--mustard) 60%); }

.wall {
  max-width: 1200px; margin: 0 auto; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 44px 40px;
}
.sticker-card {
  margin: 0; width: 260px; padding: 12px 12px 16px; background: #fffaf0; border-radius: 28px; text-align: center;
  transition: transform .25s ease;
}
.sticker-card img { border-radius: 20px; background: linear-gradient(170deg, #f7b58a, var(--pink)); aspect-ratio: 1; object-fit: cover; }
.sticker-card figcaption { margin-top: 10px; font-weight: 700; font-size: 24px; }
.sticker-card.in:hover { transform: rotate(0deg) scale(1.05); }
.pill { margin: 0; padding: 10px 24px; background: #fffaf0; border-radius: 999px; font-family: var(--display); font-size: 30px; }
.pill-pink { background: var(--pink); }
.pill-plum { background: var(--plum); color: #fffaf0; }
.pill-mustard { background: var(--mustard); }

.tuck-row { max-width: 1000px; margin: 0 auto; display: grid; justify-items: center; gap: 50px; text-align: center; }
.tuck-copy { margin: 0; font-size: 30px; font-weight: 700; max-width: 26ch; }
.tuck-links { display: flex; gap: 22px; flex-wrap: wrap; justify-content: center; }

/* the contract-address slot: a luggage tag */
.tag {
  position: relative; display: flex; align-items: center; gap: 14px; min-width: min(520px, 100%); max-width: 100%;
  padding: 18px 26px 18px 64px; background: var(--mustard); border-radius: 12px 40px 40px 12px;
}
.tag-hole { position: absolute; left: 20px; top: 50%; width: 22px; height: 22px; margin-top: -11px; background: var(--knit); border: 3px solid var(--ink); border-radius: 50%; }
.tag-label { font-family: var(--display); font-size: 30px; }
.tag-value {
  flex: 1; min-width: 0; min-height: 1.4em; padding: 4px 10px; background: #fffaf0; border: 3px dashed var(--ink); border-radius: 10px;
  font-family: ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.tag-tools { display: flex; gap: 8px; }
.tag-tools:empty { display: none; }
.tool {
  display: inline-grid; place-items: center; min-width: 44px; height: 44px; padding: 0 10px; background: #fffaf0; border: 3px solid var(--ink); border-radius: 12px;
  font: 700 18px var(--hand); cursor: pointer; color: var(--ink); text-decoration: none; transition: transform .15s ease;
}
.tool svg { width: 22px; height: 22px; }
.tool:hover, .tool:focus-visible { transform: translateY(-2px) rotate(-3deg); }
.tool:active { transform: scale(.94); }
.tool.copied { background: var(--pink); }

/* footer: a sticker strip along the blanket's hem */
.hem {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 30px;
  padding: 50px clamp(18px, 4vw, 48px) 60px; background: var(--plum); border-top: var(--outline); color: var(--ink);
}
.hem-brand { display: inline-flex; align-items: center; gap: 12px; padding: 6px 18px 6px 6px; background: #fffaf0; border-radius: 999px; font-family: var(--display); font-size: 26px; }
.hem-brand img { width: 44px; height: 44px; border-radius: 50%; border: 3px solid var(--ink); }
.hem-brand b { font-weight: 400; color: var(--orange); }
.tag-sm { min-width: 0; flex: 0 1 460px; padding: 12px 18px 12px 18px; }
.icons { display: flex; gap: 16px; }
.icon {
  display: grid; place-items: center; width: 56px; height: 56px; background: var(--mustard); border: 3px solid var(--ink); border-radius: 50%;
  color: var(--ink); transition: transform .18s ease, background .18s ease;
}
.icon svg { width: 28px; height: 28px; }
.icon:hover, .icon:focus-visible { transform: rotate(-10deg) scale(1.1); background: var(--pink); }
.icon:active { transform: scale(.92); }

@media (max-width: 860px) {
  body { font-size: 20px; }
  .hero { grid-template-columns: 1fr; grid-template-areas: "hanger" "art" "word" "tag" "links"; padding-top: 28px; }
  .hanger { width: 200px; padding: 64px 16px 20px; justify-self: end; margin: 0 8px -70px 0; z-index: 2; }
  .hanger-big { font-size: 44px; }
  .hero-art { margin: 0 6px; }
  .wordmark { margin-top: 30px; }
  .tagline { margin: 90px 0 0 10px; font-size: 26px; }
  .word-row { grid-template-columns: auto auto auto; }
  .note { grid-column: 1 / -1; }
  .word { padding: 6px 12px; font-size: 34px; }
  .word-row { gap: 16px 12px; }
  .arrow { font-size: 40px; }
  .patch { width: 72px; height: 72px; font-size: 32px; top: -70px; left: auto; right: 4px; }
  .story { font-size: 23px; }
  .sticker-card { width: min(300px, 80vw); }
  .tabs { gap: 18px; }
  .tab { font-size: 18px; padding: 2px 12px; }
  .tag { padding-left: 54px; flex-wrap: wrap; }
  .tag-value { order: 3; flex-basis: 100%; text-align: center; font-size: 17px; }
  .tag-tools { margin-left: auto; }
  .tag-sm { padding-left: 18px; }
  .tag-label { font-size: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  .sky, .zzz span, .hanger { animation: none; }
  .zzz { display: none; }
  .slap { opacity: 1; transform: rotate(var(--r, 0deg)); transition: none; }
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
