:root {
  --ink: #161616;
  --cream: #f3ead5;
  --gold: #927644;
  --rust: #981f14;
  --ochre: #b66a12;
  --sage: #586c5c;
  --tan: #bf9657;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  min-height: 100%;
}

body {
  margin: 0;
  min-height: 100%;
  background: #101010;
  color: var(--cream);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

body.admin-page {
  min-height: 100svh;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .78), rgba(0, 0, 0, .5)),
    url("../assets/studio-room.png") center / cover fixed no-repeat;
}

button,
input {
  font: inherit;
}

button {
  border-radius: 0;
}

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

.secret-shell {
  min-height: 100svh;
}

.secret-hero {
  min-height: 100svh;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(22px, 4vw, 56px);
  display: grid;
  align-items: center;
}

.secret-bg {
  position: absolute;
  inset: 0;
  z-index: -3;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .62), rgba(0, 0, 0, .32) 45%, rgba(0, 0, 0, .78)),
    url("../assets/studio-room.png") center / cover no-repeat;
}

.secret-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .26);
}

.wave {
  position: absolute;
  left: -8vw;
  right: -8vw;
  height: 42vh;
  z-index: -2;
  opacity: .42;
  transform: rotate(-2deg);
}

.wave::before,
.wave::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--rust);
  clip-path: polygon(0 35%, 16% 48%, 31% 43%, 46% 26%, 61% 19%, 78% 33%, 100% 20%, 100% 100%, 0 100%);
}

.wave::after {
  top: 18%;
  background: var(--ochre);
  clip-path: polygon(0 28%, 18% 42%, 37% 50%, 55% 32%, 72% 20%, 89% 28%, 100% 45%, 100% 100%, 0 100%);
}

.wave-one {
  bottom: -17vh;
}

.wave-two {
  bottom: -25vh;
  opacity: .36;
  transform: rotate(1.6deg);
}

.wave-two::before {
  background: var(--sage);
  clip-path: polygon(0 25%, 14% 39%, 35% 48%, 53% 35%, 69% 18%, 86% 23%, 100% 41%, 100% 100%, 0 100%);
}

.wave-two::after {
  background: var(--tan);
  clip-path: polygon(0 44%, 17% 52%, 34% 54%, 50% 43%, 69% 26%, 85% 20%, 100% 34%, 100% 100%, 0 100%);
}

.secret-header {
  position: absolute;
  top: clamp(22px, 4vw, 52px);
  left: clamp(22px, 4vw, 56px);
  right: clamp(22px, 4vw, 56px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: rgba(243, 234, 213, .72);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .04em;
}

.secret-logo {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  object-fit: cover;
  transition: transform .9s cubic-bezier(.2, .8, .2, 1);
}

.secret-logo:hover {
  transform: rotate(360deg);
}

.session-bar {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.session-bar button,
.admin-actions button {
  appearance: none;
  border: 1px solid rgba(243, 234, 213, .28);
  background: rgba(255, 255, 255, .04);
  color: var(--cream);
  padding: 8px 10px;
  cursor: pointer;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: .03em;
}

.session-bar button:hover,
.admin-actions button:hover {
  border-color: var(--gold);
}

.secret-shell.is-locked {
  filter: blur(8px);
  pointer-events: none;
  user-select: none;
}

.auth-gate {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(0, 0, 0, .72);
}

.auth-card {
  width: min(420px, 100%);
  padding: 28px;
  background: rgba(15, 15, 15, .94);
  border: 1px solid rgba(243, 234, 213, .22);
  box-shadow: 0 28px 90px rgba(0, 0, 0, .45);
}

.auth-card h2 {
  margin: 0 0 22px;
  color: #fff;
  font-size: 34px;
  line-height: 1;
}

.auth-card label {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  color: rgba(243, 234, 213, .72);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.auth-card input {
  min-height: 46px;
  border: 1px solid rgba(243, 234, 213, .24);
  background: rgba(255, 255, 255, .05);
  color: var(--cream);
  padding: 12px;
  outline: none;
}

.auth-card input:focus {
  border-color: var(--gold);
}

.auth-card button {
  width: 100%;
  margin-top: 18px;
  border: 1px solid var(--cream);
  background: var(--cream);
  color: var(--ink);
  padding: 13px 14px;
  font-weight: 850;
  text-transform: uppercase;
  cursor: pointer;
}

.auth-error {
  margin: 14px 0 0;
  color: #ffb0a8;
  font-size: 13px;
}

.player {
  width: min(1180px, 100%);
  margin: 72px auto 0;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(340px, .95fr);
  gap: clamp(34px, 6vw, 86px);
  align-items: center;
}

.player-copy {
  max-width: 700px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--gold);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .05em;
  font-weight: 850;
}

h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(24px, 3.4vw, 54px);
  line-height: .98;
  max-width: 520px;
  font-weight: 850;
}

.intro {
  max-width: 560px;
  margin: 16px 0 0;
  font-size: clamp(28px, 5.5vw, 82px);
  line-height: .92;
  color: rgba(243, 234, 213, .9);
  font-weight: 850;
}

.deck {
  position: relative;
  padding: clamp(22px, 3vw, 34px);
  background: rgba(15, 15, 15, .82);
  border: 1px solid rgba(243, 234, 213, .18);
  box-shadow: 0 24px 80px rgba(0, 0, 0, .32);
  backdrop-filter: blur(12px);
}

.deck::before {
  content: "";
  position: absolute;
  inset: 0;
  border-top: 5px solid var(--gold);
  pointer-events: none;
}

.now-label {
  margin: 0 0 8px;
  color: var(--gold);
  text-transform: uppercase;
  font-weight: 850;
  font-size: 11px;
  letter-spacing: .05em;
}

.now h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(28px, 4vw, 52px);
  line-height: .96;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

.now h2.is-long-title {
  font-size: clamp(25px, 3.2vw, 44px);
}

.now h2.is-very-long-title {
  font-size: clamp(22px, 2.6vw, 34px);
  line-height: 1.04;
}

.now p:last-child {
  margin: 12px 0 0;
  color: rgba(243, 234, 213, .66);
  font-size: 15px;
  line-height: 1.35;
}

.controls {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 28px 0 22px;
}

.video-frame {
  position: relative;
  margin: 22px 0 0;
  background: #050505;
  border: 1px solid rgba(243, 234, 213, .18);
  overflow: hidden;
}

.video-frame video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #050505;
  object-fit: contain;
}

.fullscreen-button {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  appearance: none;
  border: 1px solid rgba(243, 234, 213, .5);
  background: rgba(15, 15, 15, .72);
  color: var(--cream);
  padding: 8px 10px;
  cursor: pointer;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.fullscreen-button:hover {
  border-color: var(--gold);
  color: #fff;
}

.video-cover {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  gap: 14px;
  border: 0;
  background:
    radial-gradient(circle at center, rgba(0, 0, 0, .12), rgba(0, 0, 0, .52)),
    linear-gradient(180deg, rgba(0, 0, 0, .05), rgba(0, 0, 0, .5));
  color: #fff;
  cursor: pointer;
  padding: clamp(18px, 4vw, 44px);
  text-align: center;
}

.video-cover[hidden] {
  display: none;
}

.video-cover-play {
  width: clamp(64px, 8vw, 92px);
  height: clamp(64px, 8vw, 92px);
  border-radius: 50%;
  background: rgba(243, 234, 213, .96);
  color: var(--ink);
  display: grid;
  place-items: center;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .42);
  transition: transform .2s ease, background .2s ease;
}

.video-cover-play::before {
  content: "";
  width: 0;
  height: 0;
  margin-left: 6px;
  border-left: 24px solid currentColor;
  border-top: 15px solid transparent;
  border-bottom: 15px solid transparent;
}

.video-cover-title {
  max-width: min(520px, 90%);
  color: var(--cream);
  font-size: clamp(21px, 3vw, 38px);
  font-weight: 850;
  line-height: 1;
  text-shadow: 0 10px 34px rgba(0, 0, 0, .72);
}

.video-cover:hover .video-cover-play {
  transform: scale(1.06);
  background: #fff;
}

.icon-button,
.play-button {
  appearance: none;
  border: 1px solid rgba(243, 234, 213, .36);
  background: transparent;
  color: var(--cream);
  cursor: pointer;
  display: grid;
  place-items: center;
}

.icon-button {
  width: 46px;
  height: 46px;
}

.play-button {
  width: 74px;
  height: 74px;
  border-radius: 50%;
  background: var(--cream);
  color: var(--ink);
}

.icon-button span,
.play-button span {
  display: block;
  width: 0;
  height: 0;
}

.play-button span {
  margin-left: 5px;
  border-left: 21px solid currentColor;
  border-top: 13px solid transparent;
  border-bottom: 13px solid transparent;
}

.is-playing .play-button span {
  width: 22px;
  height: 26px;
  margin-left: 0;
  border: 0;
  border-left: 7px solid currentColor;
  border-right: 7px solid currentColor;
}

.icon-button span {
  width: 20px;
  height: 20px;
  border-left: 3px solid currentColor;
  border-bottom: 3px solid currentColor;
  transform: rotate(45deg);
}

.icon-button.next span {
  transform: rotate(225deg);
}

.progress-wrap {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 42px;
  align-items: center;
  gap: 12px;
  color: rgba(243, 234, 213, .68);
  font-size: 12px;
}

.progress-wrap input {
  width: 100%;
  accent-color: var(--gold);
}

.progress-field {
  position: relative;
  display: grid;
  align-items: center;
}

.progress-field input {
  position: relative;
  z-index: 1;
}

.comment-markers {
  position: absolute;
  inset: 50% 0 auto;
  z-index: 2;
  height: 0;
  pointer-events: none;
}

.comment-marker {
  position: absolute;
  top: 0;
  width: 15px;
  height: 15px;
  padding: 0;
  border: 2px solid #101010;
  background: var(--gold);
  border-radius: 50% 50% 50% 0;
  box-shadow: 0 0 0 2px rgba(243, 234, 213, .34), 0 5px 14px rgba(0, 0, 0, .42);
  transform: translate(-50%, -115%) rotate(-45deg);
  cursor: pointer;
  pointer-events: auto;
  transition: background .18s ease, box-shadow .18s ease, transform .18s ease;
}

.comment-marker::after {
  content: none;
}

.comment-marker:hover,
.comment-marker.is-highlighted {
  background: var(--cream);
  box-shadow: 0 0 0 3px rgba(146, 118, 68, .65), 0 8px 18px rgba(0, 0, 0, .48);
  transform: translate(-50%, -128%) rotate(-45deg);
}

.playlist {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
  display: grid;
  gap: 0;
  border-top: 1px solid rgba(243, 234, 213, .15);
}

.playlist button {
  appearance: none;
  width: 100%;
  padding: 15px 0;
  border: 0;
  border-bottom: 1px solid rgba(243, 234, 213, .13);
  background: transparent;
  color: var(--cream);
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: baseline;
  text-align: left;
  cursor: pointer;
}

.track-main {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.track-index {
  color: var(--gold);
  font-size: 12px;
  font-weight: 850;
}

.track-title {
  font-size: clamp(13px, 1.4vw, 17px);
  line-height: 1.2;
  font-weight: 750;
  overflow-wrap: anywhere;
}

.track-meta {
  font-size: 12px;
  color: rgba(243, 234, 213, .62);
}

.track-comments {
  position: relative;
  display: inline-block;
  min-width: 38px;
  padding-left: 25px;
  color: rgba(243, 234, 213, .68);
  font-size: 12px;
  font-weight: 850;
  text-align: right;
}

.track-comments::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 17px;
  height: 13px;
  border: 2px solid currentColor;
  border-radius: 10px;
  box-shadow: inset 0 -4px 0 rgba(255, 255, 255, .04);
  transform: translateY(-50%);
}

.track-comments::after {
  content: "";
  position: absolute;
  left: 11px;
  top: 50%;
  width: 5px;
  height: 5px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  background: rgba(15, 15, 15, .82);
  transform: translateY(2px) rotate(45deg);
}

.playlist button[aria-current="true"] .track-title {
  color: var(--gold);
}

.playlist button[aria-current="true"] .track-comments {
  color: var(--gold);
}

.player-note {
  margin: 18px 0 0;
  color: rgba(243, 234, 213, .56);
  font-size: 12px;
  line-height: 1.45;
}

.player-note strong {
  color: rgba(243, 234, 213, .86);
}

.downloads-panel {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid rgba(243, 234, 213, .14);
}

.download-list {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

.download-link {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  padding: 11px 12px;
  border: 1px solid rgba(243, 234, 213, .18);
  background: rgba(255, 255, 255, .035);
  color: var(--cream);
  font-size: 13px;
  font-weight: 800;
}

.download-link:hover {
  border-color: var(--gold);
  background: rgba(146, 118, 68, .12);
}

.download-link small {
  color: var(--gold);
  font-size: 11px;
  text-transform: uppercase;
  white-space: nowrap;
}

.comments {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid rgba(243, 234, 213, .16);
}

.comments-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 14px;
}

.comments h3 {
  margin: 0;
  color: #fff;
  font-size: 25px;
  line-height: 1;
}

.comments-track {
  margin: 7px 0 0;
  color: rgba(243, 234, 213, .58);
  font-size: 12px;
  line-height: 1.3;
}

.comments-head span {
  min-width: 54px;
  padding: 6px 9px;
  border: 1px solid rgba(243, 234, 213, .25);
  color: var(--gold);
  text-align: center;
  font-size: 12px;
  font-weight: 850;
}

.comment-label {
  display: grid;
  gap: 8px;
  color: rgba(243, 234, 213, .7);
  font-size: 12px;
  text-transform: uppercase;
  font-weight: 850;
  letter-spacing: .04em;
}

.comment-label input,
.comment-label textarea {
  width: 100%;
  border: 1px solid rgba(243, 234, 213, .22);
  background: rgba(255, 255, 255, .04);
  color: var(--cream);
  padding: 13px;
  line-height: 1.4;
  outline: none;
}

.comment-author {
  margin-bottom: 12px;
}

.comment-label input {
  min-height: 46px;
}

.comment-label textarea {
  resize: vertical;
  min-height: 92px;
}

.comment-label input:focus,
.comment-label textarea:focus {
  border-color: var(--gold);
}

.comment-label input[aria-invalid="true"] {
  border-color: var(--rust);
  box-shadow: 0 0 0 1px var(--rust);
}

.comment-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.comment-actions button {
  appearance: none;
  border: 1px solid rgba(243, 234, 213, .28);
  background: transparent;
  color: var(--cream);
  padding: 11px 13px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: .03em;
}

.comment-actions button:first-child {
  background: var(--cream);
  border-color: var(--cream);
  color: var(--ink);
}

.comment-actions button:hover {
  border-color: var(--gold);
}

.comment-list {
  list-style: none;
  padding: 0;
  margin: 18px 0 0;
  display: grid;
}

.comment-list li {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  gap: 12px;
  padding: 12px 0;
  border-top: 1px solid rgba(243, 234, 213, .12);
  transition: background .18s ease, border-color .18s ease;
}

.comment-list li.is-highlighted {
  background: rgba(146, 118, 68, .14);
  border-color: rgba(146, 118, 68, .55);
}

.comment-list time,
.comment-list button {
  color: var(--gold);
  font-size: 12px;
  font-weight: 850;
}

.comment-list button {
  appearance: none;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.comment-list .comment-delete {
  align-self: start;
  border: 1px solid rgba(243, 234, 213, .18);
  padding: 5px 7px;
  color: rgba(243, 234, 213, .62);
  font-size: 10px;
  text-align: center;
  text-transform: uppercase;
}

.comment-list .comment-delete:hover {
  border-color: var(--gold);
  color: var(--cream);
}

.comment-list p {
  margin: 0;
  color: rgba(243, 234, 213, .84);
  font-size: 14px;
  line-height: 1.35;
}

.comment-list strong {
  display: block;
  margin-bottom: 3px;
  color: var(--cream);
  font-size: 11px;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.empty-comments {
  margin: 16px 0 0;
  color: rgba(243, 234, 213, .5);
  font-size: 13px;
  line-height: 1.35;
}

.empty-comments[hidden] {
  display: none;
}

.admin-actions {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(243, 234, 213, .12);
}

.admin-shell {
  width: min(1080px, calc(100% - 32px));
  min-height: 100svh;
  margin: 0 auto;
  padding: clamp(26px, 5vw, 58px) 0;
  color: var(--cream);
}

.admin-panel {
  margin-top: 28px;
  padding: clamp(20px, 3vw, 34px);
  background: rgba(15, 15, 15, .88);
  border: 1px solid rgba(243, 234, 213, .18);
}

.drop-zone {
  display: grid;
  place-items: center;
  min-height: 220px;
  margin-top: 18px;
  border: 2px dashed rgba(243, 234, 213, .28);
  background: rgba(255, 255, 255, .04);
  color: rgba(243, 234, 213, .78);
  text-align: center;
  cursor: pointer;
}

.drop-zone.is-dragging {
  border-color: var(--gold);
  background: rgba(146, 118, 68, .16);
}

.admin-grid {
  display: grid;
  grid-template-columns: minmax(0, .75fr) minmax(0, 1.25fr);
  gap: 20px;
}

.admin-panel input,
.admin-panel select {
  width: 100%;
  min-height: 44px;
  margin-top: 8px;
  border: 1px solid rgba(243, 234, 213, .24);
  background: rgba(255, 255, 255, .05);
  color: var(--cream);
  padding: 10px 12px;
}

.file-list {
  list-style: none;
  padding: 0;
  margin: 18px 0 0;
  display: grid;
  gap: 10px;
}

.file-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 11px 0;
  border-top: 1px solid rgba(243, 234, 213, .12);
  color: rgba(243, 234, 213, .82);
  font-size: 14px;
}

.file-list span:first-child {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.file-list strong {
  overflow-wrap: anywhere;
}

.file-list small {
  color: rgba(243, 234, 213, .48);
  font-size: 11px;
}

.file-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.file-list a {
  color: var(--gold);
}

.file-list button {
  appearance: none;
  border: 1px solid rgba(243, 234, 213, .2);
  background: transparent;
  color: rgba(243, 234, 213, .7);
  padding: 6px 8px;
  cursor: pointer;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.file-list button:hover {
  border-color: var(--gold);
  color: var(--cream);
}

.video-secret .player {
  width: min(980px, 100%);
  grid-template-columns: minmax(0, 1fr);
  justify-content: center;
  gap: 0;
}

.video-secret .player-copy {
  display: none;
}

.video-secret .intro {
  font-size: clamp(24px, 4vw, 56px);
}

.video-secret .deck {
  padding: clamp(20px, 2.2vw, 30px);
}

.video-secret .video-frame {
  margin-top: 18px;
}

.video-secret .controls {
  margin: 22px 0 18px;
}

@media (max-width: 860px) {
  .secret-hero {
    align-items: start;
    padding-top: 108px;
  }

  .player {
    grid-template-columns: 1fr;
    margin-top: 0;
  }

  .video-secret .player {
    grid-template-columns: 1fr;
  }

  .deck {
    margin-bottom: 24px;
  }
}

@media (max-width: 560px) {
  .secret-header {
    font-size: 10px;
  }

  .playlist button {
    grid-template-columns: 24px minmax(0, 1fr) auto;
  }
}
