@import url("https://fonts.googleapis.com/css2?family=DM+Mono:wght@300;400;500&family=Manrope:wght@300;400;500&display=swap");

:root {
  color-scheme: dark;
  --ink: #08090a;
  --paper: #e8e5dd;
  --muted: #8f908d;
  --line: rgba(232, 229, 221, 0.17);
  --signal: #d45d3c;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 79% 28%, rgba(177, 193, 190, 0.16), transparent 26rem),
    linear-gradient(112deg, #08090a 0%, #0d1011 47%, #202728 100%);
  color: var(--paper);
  font-family: "Manrope", sans-serif;
  font-weight: 300;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  opacity: 0.19;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.92' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.44'/%3E%3C/svg%3E");
}

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

#atmosphere {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
  opacity: 0.55;
}

.threshold {
  position: fixed;
  top: -20vh;
  left: 57%;
  width: 1px;
  height: 145vh;
  background: linear-gradient(transparent, rgba(232, 229, 221, 0.32), transparent);
  transform: rotate(13deg);
  transform-origin: top;
  pointer-events: none;
}

.site-header {
  height: 112px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 0 4.5vw;
  border-bottom: 1px solid var(--line);
}

.wordmark {
  width: clamp(145px, 13vw, 205px);
  display: block;
  text-decoration: none;
}

.wordmark img { display: block; width: 100%; height: auto; }

.header-state, .sound-toggle, .meta, .eyebrow, .site-footer {
  font-family: "DM Mono", monospace;
  font-size: 0.66rem;
  letter-spacing: 0.14em;
}

.header-state { display: flex; align-items: center; gap: 0.7rem; color: var(--muted); }
.live-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--signal); box-shadow: 0 0 14px var(--signal); }

.sound-toggle {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.sound-bars { height: 16px; display: flex; align-items: center; gap: 2px; }
.sound-bars i { display: block; width: 1px; height: 5px; background: var(--paper); transition: height 300ms ease; }
.sound-toggle.playing .sound-bars i:nth-child(1) { animation: level 0.8s infinite alternate; }
.sound-toggle.playing .sound-bars i:nth-child(2) { animation: level 0.56s 0.1s infinite alternate; }
.sound-toggle.playing .sound-bars i:nth-child(3) { animation: level 0.72s 0.2s infinite alternate; }
.sound-toggle.playing .sound-bars i:nth-child(4) { animation: level 0.48s infinite alternate; }

.room {
  min-height: calc(100vh - 184px);
  display: grid;
  grid-template-columns: minmax(300px, 0.9fr) minmax(370px, 1.2fr) minmax(180px, 0.45fr);
  align-items: center;
  gap: 3vw;
  padding: 5vh 4.5vw 7vh;
}

.eyebrow, .meta { color: var(--muted); }
.room-copy { align-self: center; }

.room-copy h1 {
  max-width: 650px;
  margin: 1.4rem 0 1.8rem;
  font-size: clamp(3.15rem, 5.3vw, 7rem);
  line-height: 0.93;
  letter-spacing: -0.065em;
  font-weight: 300;
}

.intro {
  max-width: 30rem;
  margin: 0;
  color: #aaa9a4;
  font-size: clamp(1rem, 1.25vw, 1.18rem);
  line-height: 1.7;
}

.player-stage {
  position: relative;
  width: min(42vw, 610px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  justify-self: center;
}

.orbit {
  position: absolute;
  border: 1px solid var(--line);
  border-radius: 50%;
  pointer-events: none;
}
.orbit-one { inset: 2%; }
.orbit-two { inset: 12%; border-style: dashed; opacity: 0.45; animation: spin 55s linear infinite reverse; }

.record {
  position: relative;
  width: 65%;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 50%;
  padding: 0;
  background: repeating-radial-gradient(circle, #080808 0 2px, #101112 3px 5px, #080808 6px 8px);
  box-shadow: 0 36px 80px rgba(0,0,0,0.5), inset 0 0 30px rgba(255,255,255,0.02);
  cursor: pointer;
  transition: transform 900ms var(--ease), box-shadow 900ms var(--ease);
}

.record:hover { transform: scale(1.018); box-shadow: 0 45px 110px rgba(0,0,0,0.65); }
.record.playing { animation: spin 22s linear infinite; }
.record-rings { position: absolute; inset: 11%; border: 1px solid rgba(255,255,255,0.08); border-radius: 50%; }

.record-label {
  width: 35%;
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  border-radius: 50%;
  background: #c9c6bd;
  color: #121313;
  font-family: "DM Mono", monospace;
}
.record-label strong { font-size: clamp(0.65rem, 1vw, 0.85rem); letter-spacing: 0.12em; }
.record-label small { font-size: clamp(0.35rem, 0.5vw, 0.5rem); letter-spacing: 0.08em; }

.tonearm { position: absolute; width: 38%; height: 50%; top: 5%; right: 1%; pointer-events: none; transform-origin: 82% 10%; transition: transform 1.2s var(--ease); }
.tonearm .pivot { position: absolute; top: 0; right: 0; width: 17%; aspect-ratio: 1; border: 1px solid #747876; border-radius: 50%; background: #1d2020; }
.tonearm .arm { position: absolute; top: 7%; right: 8%; width: 2px; height: 72%; background: linear-gradient(#949994, #393c3b); transform: rotate(-18deg); transform-origin: top; }
.tonearm .needle { position: absolute; left: 22%; bottom: 14%; width: 9%; height: 17%; border: 1px solid #777; transform: rotate(-18deg); }
.player-stage.playing .tonearm { transform: rotate(18deg); }

.track-card {
  position: absolute;
  left: 1%;
  right: 1%;
  bottom: -1rem;
  display: flex;
  align-items: end;
  justify-content: space-between;
  padding: 1rem 0;
  border-top: 1px solid var(--line);
  font-family: "DM Mono", monospace;
}
.track-card div { display: grid; gap: 0.45rem; }
.track-card strong { max-width: 25rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 0.72rem; font-weight: 400; letter-spacing: 0.08em; }
#play-state { color: var(--muted); font-size: 0.59rem; letter-spacing: 0.12em; }
.soundcloud-mount { position: absolute; width: 1px; height: 1px; overflow: hidden; opacity: 0; pointer-events: none; }

.room-data { display: grid; gap: 2.8rem; padding-left: 2.2vw; border-left: 1px solid var(--line); }
.room-data div { display: grid; gap: 0.55rem; }
.room-data strong { font-family: "DM Mono", monospace; font-size: 0.72rem; font-weight: 400; letter-spacing: 0.08em; }

.site-footer {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 0 4.5vw;
  border-top: 1px solid var(--line);
  color: var(--muted);
}
.site-footer nav { display: flex; gap: 2rem; }
.site-footer a { text-underline-offset: 0.3rem; }

.entry {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: #090a0b;
  transition: opacity 1.1s var(--ease), visibility 1.1s;
}
.entry::before { content: ""; position: absolute; width: min(60vw, 700px); aspect-ratio: 1; border: 1px solid var(--line); border-radius: 50%; }
.entry > * { position: relative; z-index: 1; }
.entry-logo { width: clamp(190px, 20vw, 320px); height: auto; }
.entry h2 { margin: 1.5rem 0 2.5rem; font-size: clamp(2.7rem, 5vw, 5.5rem); line-height: 0.98; letter-spacing: -0.055em; font-weight: 300; }
.entry button { padding: 1.15rem 1.7rem; border: 1px solid rgba(232,229,221,0.35); background: transparent; font-family: "DM Mono", monospace; font-size: 0.66rem; letter-spacing: 0.12em; cursor: pointer; transition: background 300ms, color 300ms; }
.entry button:hover { background: var(--paper); color: var(--ink); }
.entry small { margin-top: 1rem; color: #666; font-family: "DM Mono", monospace; font-size: 0.58rem; letter-spacing: 0.1em; }
.entry.closed { opacity: 0; visibility: hidden; }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes level { from { height: 3px; } to { height: 15px; } }

@media (max-width: 1050px) {
  .room { grid-template-columns: 0.85fr 1.15fr; }
  .room-data { display: none; }
  .player-stage { width: min(53vw, 560px); }
}

@media (max-width: 720px) {
  .site-header { height: 84px; grid-template-columns: 1fr auto; }
  .header-state { display: none; }
  .room { min-height: auto; grid-template-columns: 1fr; gap: 2.5rem; padding-top: 8vh; padding-bottom: 12vh; }
  .room-copy h1 { font-size: clamp(3.4rem, 15vw, 5.3rem); }
  .intro { max-width: 92%; }
  .player-stage { width: 92vw; max-width: 560px; }
  .site-footer { align-items: flex-start; flex-direction: column; padding-top: 1.5rem; padding-bottom: 1.5rem; }
  .site-footer nav { width: 100%; justify-content: space-between; }
  .threshold { left: 72%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
}
