/* iloily.com — ilo's autumn
   ---------------------------------------------------------------
   warm paper, pumpkin and rust, taken straight from ilo's hair.
   one page: hello, now playing, three cards, a leaf pile.        */

:root {
  --paper:   #fffaf0;   /* the cards */
  --cream:   #fbf0dc;   /* the page */
  --oat:     #f4e1bf;   /* anything sunk into a card */
  --honey:   #f3c46a;   /* her hoodie; highlights, the tape */
  --pumpkin: #e9793a;   /* decoration only, never text on cream */
  --rust:    #b4472a;   /* filled buttons, the ribbon */
  --brick:   #8a3320;   /* links, small labels */
  --cocoa:   #5a3524;   /* secondary text */
  --bark:    #2d1a12;   /* body text, every outline */
  --blush:   #f4b39a;   /* her cheeks; one soft accent */

  --display: 'Fraunces', Georgia, serif;
  --body: 'Manrope', system-ui, sans-serif;
  --hand: 'Gochi Hand', 'Comic Sans MS', cursive;

  --shadow: 4px 5px 0 var(--bark);
  --maple: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2l1.6 3.6 2.6-1.2-.6 4.2 3.4-1.8-.8 2.6 3.8.8-3 2.6 1 1.6-4.4.2.4 2.8-3.6-2.4-.4 4.6h-.8l-.4-4.6-3.6 2.4.4-2.8-4.4-.2 1-1.6-3-2.6 3.8-.8-.8-2.6 3.4 1.8-.6-4.2 2.6 1.2z'/%3E%3C/svg%3E");
  --oval:  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 1C6 6 5 13 11 20v3h2v-3c6-7 5-14-1-19z'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  font: 500 16px/1.6 var(--body);
  color: var(--bark);
  background:
    radial-gradient(60rem 30rem at 12% -6%, #fde3b8 0%, transparent 60%),
    radial-gradient(50rem 30rem at 100% 30%, #f9d9c2 0%, transparent 55%),
    var(--cream);
  overflow-x: hidden;
}
/* paper grain over everything, never in the way of a click */
body::before {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: .22;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .35 0 0 0 0 .2 0 0 0 0 .1 0 0 0 .5 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

img { display: block; max-width: 100%; height: auto; }
a { color: var(--brick); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--rust); }
:focus-visible { outline: 3px solid var(--rust); outline-offset: 3px; border-radius: 6px; }

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  padding: 8px 14px; border-radius: 10px;
  background: var(--bark); color: var(--paper);
}
.skip:focus { top: 12px; }

/* ───────────── falling leaves ───────────── */
.sky { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.leaf {
  position: absolute; top: -40px; left: var(--x);
  width: var(--s); height: var(--s);
  background: var(--rust);
  -webkit-mask: var(--maple) center / contain no-repeat;
          mask: var(--maple) center / contain no-repeat;
  opacity: .8;
  animation: fall var(--d) linear var(--t) infinite;
}
.leaf--b { background: var(--pumpkin); }
.leaf--c { background: var(--honey); -webkit-mask-image: var(--oval); mask-image: var(--oval); }
.leaf--d { background: var(--brick); -webkit-mask-image: var(--oval); mask-image: var(--oval); }

@keyframes fall {
  0%   { transform: translate(0, 0) rotate(0); }
  25%  { transform: translate(var(--w), 25vh) rotate(120deg); }
  50%  { transform: translate(0, 52vh) rotate(200deg); }
  75%  { transform: translate(calc(var(--w) * -1), 78vh) rotate(300deg); }
  100% { transform: translate(0, 108vh) rotate(400deg); }
}

/* ───────────── ribbon ───────────── */
.ribbon {
  position: relative; z-index: 2;
  overflow: hidden;
  background: var(--rust);
  color: var(--paper);
  border-bottom: 3px solid var(--bark);
  font: 400 1.15rem/1 var(--hand);
  padding: 9px 0 7px;
  white-space: nowrap;
}
.ribbon__track { display: inline-flex; animation: slide 38s linear infinite; }
.ribbon__track span { padding-right: .4em; }
@keyframes slide { to { transform: translateX(-50%); } }

/* ───────────── layout ───────────── */
main {
  position: relative; z-index: 1;
  width: min(1080px, 100% - 32px);
  margin: 0 auto;
}

/* ───────────── hello ───────────── */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 400px) minmax(0, 1fr);
  align-items: center;
  gap: clamp(28px, 6vw, 72px);
  padding: clamp(40px, 8vw, 88px) 0 clamp(36px, 6vw, 64px);
}

.badge { position: relative; aspect-ratio: 1; width: 100%; max-width: 400px; margin: 0 auto; }
.badge__ring {
  position: absolute; inset: 0; width: 100%; height: 100%;
  overflow: visible;
  animation: spin 40s linear infinite;
}
.badge__ring text {
  font: 400 14.2px var(--hand);
  letter-spacing: .12em;
  fill: var(--brick);
}
.badge__disc {
  position: absolute; inset: 14%;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 38%, #ffe7b3, var(--honey) 70%);
  border: 3px solid var(--bark);
  box-shadow: 6px 8px 0 var(--bark), inset 0 0 0 8px rgba(255, 250, 240, .55);
  overflow: hidden;
}
.badge__disc img {
  position: absolute; left: 50%; bottom: -4%;
  width: 104%; max-width: none;
  transform: translateX(-50%);
}
@keyframes spin { to { transform: rotate(360deg); } }

.hello__hi {
  margin: 0;
  font: 400 1.6rem/1 var(--hand);
  color: var(--brick);
  transform: rotate(-3deg);
  transform-origin: left;
}
.wordmark {
  margin: .05em 0 .1em;
  font: italic 900 clamp(4.2rem, 13vw, 8.4rem)/.9 var(--display);
  font-variation-settings: 'SOFT' 100, 'opsz' 144;
  letter-spacing: -.035em;
  color: var(--bark);
  text-shadow: 4px 4px 0 var(--honey);
}
.wordmark span { color: var(--rust); }
.hello__sub { margin: 0; font-size: 1.12rem; color: var(--cocoa); }
.hello__face { margin: .25em 0 1.1em; font-size: 1.3rem; color: var(--brick); }

.socials { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
.socials a {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 15px 8px 11px;
  border: 2px solid var(--bark);
  border-radius: 999px;
  background: var(--paper);
  color: var(--bark);
  font-weight: 700; font-size: .92rem;
  text-decoration: none;
  box-shadow: 2px 3px 0 var(--bark);
  transition: transform .15s, box-shadow .15s, background .15s;
}
.socials a:hover { background: var(--oat); transform: translate(-1px, -2px); box-shadow: 3px 5px 0 var(--bark); color: var(--bark); }
.socials svg {
  width: 20px; height: 20px;
  fill: none; stroke: var(--rust); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}

.notabl {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px;
  border: 2px solid var(--bark);
  border-radius: 14px;
  background: var(--rust);
  color: var(--paper);
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform .15s, box-shadow .15s;
}
.notabl:hover { color: var(--paper); transform: translate(-2px, -2px); box-shadow: 6px 7px 0 var(--bark); }
.notabl span { transition: transform .15s; }
.notabl:hover span { transform: translateX(3px); }

/* ───────────── now playing ───────────── */
.label {
  margin: 0 0 8px;
  font: 800 .78rem/1 var(--body);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--brick);
}
.np {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  align-items: center;
  gap: 26px;
  padding: 22px 26px;
  background: var(--bark);
  border-radius: 24px;
  box-shadow: 6px 8px 0 var(--rust);
}
.np .label { color: var(--honey); }
.np__record {
  position: relative;
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle, var(--honey) 0 17%, var(--bark) 17.5% 19%, transparent 19.5%),
    repeating-radial-gradient(circle, #1b0f0a 0 2px, #3a2319 2.5px 4px);
  box-shadow: 0 0 0 3px #4a2c1f;
  animation: spin 3.2s linear infinite paused;
}
.np__record span {
  position: absolute; inset: 47%;
  border-radius: 50%;
  background: var(--bark);
}
.np:has(.is-playing) .np__record { animation-play-state: running; }

.player { position: relative; min-height: 152px; }
.player iframe { display: block; border: 0; border-radius: 14px; }
.player__hint {
  margin: 8px 0 0;
  font: 400 1.05rem/1 var(--hand);
  color: var(--oat);
  transition: opacity .3s;
}
.player.is-playing .player__hint { opacity: 0; }
.player.is-idle, .player.is-dead { display: none; }
.np:has(.player.is-dead), .np:has(.player.is-idle) { display: none; }

/* ───────────── the cards ───────────── */
.cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 34px 30px;
  padding: 56px 0 30px;
}
.card {
  position: relative;
  padding: 30px 28px 26px;
  background:
    repeating-linear-gradient(transparent 0 31px, rgba(180, 71, 42, .13) 31px 32px) 0 58px / 100% calc(100% - 58px) no-repeat,
    var(--paper);
  border: 2px solid var(--bark);
  border-radius: 8px;
  box-shadow: var(--shadow);
  transform: rotate(var(--tilt, 0deg));
  transition: transform .25s;
}
.card:hover, .card:target { transform: rotate(0) translateY(-3px); }
/* a strip of tape holding it up */
.card::before {
  content: "";
  position: absolute; top: -13px; left: 50%;
  width: 96px; height: 26px;
  transform: translateX(-50%) rotate(-3deg);
  background: rgba(243, 196, 106, .82);
  border-left: 2px dashed rgba(255, 250, 240, .7);
  border-right: 2px dashed rgba(255, 250, 240, .7);
}
.card--wide {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 300px) minmax(0, 1fr);
  gap: 34px;
  align-items: start;
}
.card--wide::before { left: 70%; }
.card h2 {
  display: flex; align-items: center; gap: 10px;
  margin: 0 0 14px;
  font: italic 800 1.65rem/1.1 var(--display);
  font-variation-settings: 'SOFT' 100;
  color: var(--bark);
}
.card h2 svg { flex: none; width: 24px; height: 24px; fill: var(--pumpkin); }

.rows { margin: 0; }
.row {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 12px;
  padding: 8px 0;
  border-top: 2px dotted rgba(90, 53, 36, .25);
}
.row:first-child { border-top: 0; }
.row dt {
  font: 400 1.2rem/1.35 var(--hand);
  color: var(--rust);
}
.row dd { margin: 0; }

.note {
  margin: 16px 0 0;
  padding: 10px 14px;
  background: var(--oat);
  border-left: 4px solid var(--blush);
  border-radius: 0 10px 10px 0;
  font-size: .92rem;
  color: var(--cocoa);
}

.polaroid {
  margin: 0;
  padding: 12px 12px 6px;
  background: #fff;
  border: 2px solid var(--bark);
  box-shadow: 3px 4px 0 var(--bark);
  transform: rotate(-3deg);
}
.polaroid img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.polaroid figcaption {
  padding: 8px 0 4px;
  text-align: center;
  font: 400 1.3rem/1 var(--hand);
  color: var(--brick);
}

/* ───────────── leaf pile ───────────── */
.pile {
  position: relative; z-index: 1;
  margin-top: 40px;
  text-align: center;
}
.pile__heap { display: block; width: 100%; height: 90px; margin-top: -58px; position: relative; z-index: 1; }
.pile__foot {
  margin: 0;
  padding: 4px 16px 22px;
  background: var(--honey);
  font: 400 1.05rem/1 var(--hand);
  color: var(--bark);
}
.chibi {
  position: relative; z-index: 2;
  display: inline-block;
  margin: 0; padding: 0;
  border: 0; background: none;
  cursor: pointer;
  width: 170px;
}
.chibi img { width: 100%; transform-origin: 50% 100%; }
.chibi:hover img { animation: wobble .6s ease-in-out; }
.chibi.is-poked img { animation: hop .5s cubic-bezier(.3, 1.6, .5, 1); }
.chibi__say {
  position: absolute; top: 4px; left: 88%;
  padding: 7px 12px;
  white-space: nowrap;
  background: var(--paper);
  border: 2px solid var(--bark);
  border-radius: 14px 14px 14px 4px;
  font: 400 1.1rem/1 var(--hand);
  color: var(--brick);
  box-shadow: 2px 3px 0 var(--bark);
  transform: rotate(4deg);
}
@keyframes wobble { 25% { transform: rotate(-4deg); } 75% { transform: rotate(4deg); } }
@keyframes hop { 40% { transform: translateY(-26px) scale(1.03, .97); } }

/* the burst when she's poked */
.puff {
  position: fixed; z-index: 60; pointer-events: none;
  width: 18px; height: 18px;
  -webkit-mask: var(--maple) center / contain no-repeat;
          mask: var(--maple) center / contain no-repeat;
  animation: puff 1.1s cubic-bezier(.2, .7, .4, 1) forwards;
}
@keyframes puff {
  to { transform: translate(var(--dx), var(--dy)) rotate(var(--r)); opacity: 0; }
}

/* ───────────── small screens ───────────── */
@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; text-align: center; padding-top: 34px; }
  .badge { max-width: 300px; }
  .hello__hi { transform: rotate(-3deg); transform-origin: center; }
  .socials { justify-content: center; }
  .np { grid-template-columns: 1fr; padding: 20px 16px; }
  .np__record { width: 96px; margin: 0 auto; }
  .np .label { text-align: center; }
  .cards { grid-template-columns: 1fr; gap: 32px; padding-top: 44px; }
  .card { padding: 26px 18px 22px; }
  .card--wide { grid-template-columns: 1fr; gap: 24px; }
  .polaroid { max-width: 280px; margin: 0 auto; }
  .row { grid-template-columns: 66px minmax(0, 1fr); }
  .chibi { width: 140px; }
  .chibi__say { left: auto; right: 78%; border-radius: 14px 14px 4px 14px; transform: rotate(-4deg); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .sky { display: none; }
}
