/* Summer Blue Static — four 1080×1920 artboards, made interactive.
   Every element is placed in artboard pixels via --x --y --w --h (--r = rotation in deg). */

@font-face {
  font-family: "Janitor";
  src: url("../assets/fonts/Janitor.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; background: #111; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0 auto;
  max-width: min(100vw, 480px);
  background: #111;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  letter-spacing: -0.02em;
  color: #111;
  box-shadow: 0 0 60px rgba(0, 0, 0, 0.55);
  overflow-x: hidden;
}
@media (max-width: 600px) {
  body { box-shadow: none; }
}
html.is-landing,
html.is-landing body {
  height: 100svh;
  overflow: hidden;
}
html.is-landing #events,
html.is-landing #goods,
html.is-landing #journal,
html.is-landing #footer {
  display: none;
}
html:not(.is-landing) #top {
  display: none;
}
.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ── screens (vertical mobile layout on all devices) ── */
.screen {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
}
#top {
  min-height: 100svh;
  align-content: safe center;
  background: #cfe6fb;
}
#events  { background: #c98a45; }
#goods   { background: #ececec; }
#journal { background: #e3d5bd; }

.frame {
  position: relative;
  width: 100%;
  aspect-ratio: 9 / 16;
  container-type: inline-size;
}

.art {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  display: block;
  user-select: none; -webkit-user-drag: none;
  pointer-events: none;
}

/* artboard positioning */
.hot, .line-in, .card, .disc, .lcd, .good-tag, .anchor {
  position: absolute;
  left:   calc(var(--x, 0) / 1080 * 100%);
  top:    calc(var(--y, 0) / 1920 * 100%);
  width:  calc(var(--w, 0) / 1080 * 100%);
  height: calc(var(--h, 0) / 1920 * 100%);
  transform: rotate(calc(var(--r, 0) * 1deg));
}

/* invisible click areas laid over the drawn buttons */
.hot {
  display: block;
  margin: 0; padding: 0;
  border: 0;
  background: transparent;
  color: transparent;
  font-size: 0;
  overflow: hidden;
  cursor: pointer;
  border-radius: 1.2cqw;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}
.hot:hover { background-color: rgba(255, 255, 255, 0.22); }
.hot:active { background-color: rgba(255, 255, 255, 0.35); }
.hot:focus-visible { outline: 2px dashed #111; outline-offset: 2px; }
.landing-any { z-index: 1; border-radius: 0; }
.landing-any:hover, .landing-any:active { background-color: transparent; }
.landing-ig { z-index: 2; }
#top nav .hot { z-index: 3; }
.btn:hover, .btn:focus-visible { background-color: rgba(0, 0, 0, 0.07); }
.good:hover { background-color: rgba(255, 255, 255, 0.12); }
.good.is-on { box-shadow: inset 0 0 0 0.35cqw rgba(255, 255, 255, 0.85); }

/* goods name tag — just the item name */
.good-tag {
  width: auto; height: auto;
  margin: 0;
  padding: 0.9cqw 2cqw 0.8cqw;
  background: #111;
  color: #fff;
  font-weight: 700;
  font-size: 3.6cqw;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: -0.03em;
  white-space: nowrap;
  border-radius: 0.6cqw;
  translate: -50% -50%;
  transform: rotate(-3deg);
  pointer-events: none;
  z-index: 5;
  box-shadow: 0 0.6cqw 1.6cqw rgba(0, 0, 0, 0.3);
  animation: pop 0.22s cubic-bezier(.3, 1.6, .6, 1);
}
.good-tag small {
  display: block;
  margin-top: 0.6cqw;
  font-size: 2.3cqw;
  font-weight: 500;
  text-transform: none;
  opacity: 0.85;
}
@keyframes pop { from { opacity: 0; scale: 0.6; } }

/* ── ID card form ── */
.line-in {
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0 0.6cqw;
  font: 700 3cqw/1 "Helvetica Neue", Helvetica, Arial, sans-serif;
  letter-spacing: -0.03em;
  color: #111;
  outline: none;
}
.line-in::placeholder { color: rgba(17, 17, 17, 0.28); }
.line-in:focus { background: rgba(255, 255, 255, 0.35); }

.card {
  cursor: grab;
  touch-action: none;
  filter: drop-shadow(0 0.3cqw 0.3cqw rgba(0,0,0,0.0));
}
.card.dragging { cursor: grabbing; }

/* ── CD player ── */
.anchor { width: 1px; height: 1px; }
.disc {
  padding: 0; margin: 0; border: 0;
  background: none;
  border-radius: 50%;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  animation: spin 2.6s linear infinite;
  animation-play-state: paused;
}
.disc img { display: block; width: 100%; height: 100%; border-radius: 50%; pointer-events: none; }
.disc.playing { animation-play-state: running; }
.disc:focus-visible { outline: 2px dashed #3e5544; outline-offset: 4px; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .disc { animation-duration: 12s; } }

.lcd {
  --r: -3;
  display: grid;
  grid-template-columns: auto 1fr auto;
  grid-template-rows: 1fr 1fr;
  align-items: center;
  column-gap: 1.4cqw;
  padding: 0.5cqw 2.2cqw 0.6cqw 1.8cqw;
  background: #a0b89c;
  border-radius: 1.4cqw;
  box-shadow: inset 0 0.15cqw 0.4cqw rgba(0,0,0,0.12);
  color: #1e231e;
  font-size: 1.85cqw;
  line-height: 1;
  pointer-events: none;
}
.lcd-title { grid-column: 1 / 3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lcd-title i { font-style: normal; font-size: 1.5cqw; display: inline-block; width: 2cqw; }
.lcd-title b { font-weight: 400; }
.lcd-trk  { grid-column: 3; grid-row: 1 / 3; align-self: center; padding-top: 1.2cqw; }
.lcd-time { grid-column: 1; grid-row: 2; font-variant-numeric: tabular-nums; }
.lcd-bar  { grid-column: 2; grid-row: 2; height: 0.85cqw; background: #8aa486; border-radius: 0.2cqw; overflow: hidden; }
.lcd-bar span { display: block; height: 100%; width: 0; background: #3e5544; transition: width 0.4s linear; }

/* ── footer ── */
.site-footer {
  background: #000;
}
.footer-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 1024 / 849;
  container-type: inline-size;
}
.site-footer .hot {
  left:   calc(var(--fx, 0) / 1024 * 100%);
  top:    calc(var(--fy, 0) / 849 * 100%);
  width:  calc(var(--fw, 0) / 1024 * 100%);
  height: calc(var(--fh, 0) / 849 * 100%);
}
.site-footer .hot:hover { background-color: rgba(255, 255, 255, 0.18); }

/* ── Spotify compact 30s preview dock ── */
.sp-dock {
  position: fixed;
  right: max(12px, calc(50vw - 228px));
  top: 10px;
  z-index: 60;
  display: flex;
  flex-direction: column-reverse;
  align-items: flex-end;
  gap: 8px;
}
html.is-landing .sp-dock {
  left: 0;
  right: auto;
  top: auto;
  bottom: 0;
  z-index: -1;
  opacity: 0.001;
  pointer-events: none;
}
.sp-embed-wrap {
  width: min(300px, calc(100vw - 24px));
  height: 80px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.32);
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.sp-dock.is-collapsed .sp-embed-wrap {
  position: fixed;
  left: 0;
  bottom: 0;
  opacity: 0.001;
  pointer-events: none;
}
.sp-toggle {
  width: 48px;
  height: 48px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  display: grid;
  place-items: center;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.25));
  transition: transform 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}
.sp-toggle img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  pointer-events: none;
}
.sp-toggle:hover { transform: scale(1.06); }
.sp-toggle:focus-visible { outline: 2px dashed #111; outline-offset: 2px; }

/* ── blue music note touch / drag pop ── */
.note-pop {
  position: fixed;
  left: 0;
  top: 0;
  width: 20px;
  height: 20px;
  pointer-events: none;
  z-index: 9999;
  color: #4da6ff;
  filter: drop-shadow(0 2px 4px rgba(255, 255, 255, 0.85));
  animation: note-float 0.72s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
.note-pop svg { display: block; width: 100%; height: 100%; fill: currentColor; }
@keyframes note-float {
  0%   { opacity: 0; transform: translate(-50%, -50%) scale(0.55) rotate(var(--nr, -8deg)); }
  20%  { opacity: 1; transform: translate(-50%, -70%) scale(1.05) rotate(var(--nr, -8deg)); }
  100% { opacity: 0; transform: translate(calc(-50% + var(--nx, 8px)), -155%) scale(0.85) rotate(calc(var(--nr, -8deg) + 12deg)); }
}
@media (prefers-reduced-motion: reduce) {
  .note-pop { animation-duration: 0.45s; }
}
