/* Briyan Fredrick — site styles */
:root {
  --bg: #12100e;
  --bg-2: #1a1713;
  --bg-3: #242019;
  --ink: #ece5d8;
  --ink-dim: #a89e8c;
  --line: #332d24;
  --accent: #e0a458;
  --accent-2: #c9763d;
  --danger: #c0564b;
  --radius: 10px;
  --maxw: 1080px;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, "SF Mono", Menlo, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.15; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); margin: 0.2em 0; }
h2 { font-size: clamp(1.3rem, 3vw, 1.8rem); margin: 0.4em 0; }
code, .mono { font-family: var(--font-mono); font-size: 0.85em; }

main { min-height: 70vh; padding-bottom: 110px; }
.page { max-width: var(--maxw); margin: 0 auto; padding: 2rem 1.25rem; }
.muted { color: var(--ink-dim); }
.small { font-size: 0.85rem; }
.empty { color: var(--ink-dim); font-style: italic; }

/* header */
.site-header {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
}
.brand {
  font-family: var(--font-display);
  font-size: 1.35rem; font-weight: 700; color: var(--ink);
  letter-spacing: 0.02em;
}
.brand:hover { text-decoration: none; color: var(--accent); }
.site-header nav { display: flex; gap: 1.25rem; align-items: center; }
.site-header nav a { color: var(--ink-dim); font-size: 0.95rem; }
.site-header nav a:hover, .site-header nav a.active { color: var(--ink); text-decoration: none; }
.site-header nav a.join {
  color: var(--bg); background: var(--accent);
  padding: 0.35rem 0.9rem; border-radius: 99px; font-weight: 600;
}
.menu-toggle { display: none; background: none; border: none; color: var(--ink); font-size: 1.4rem; cursor: pointer; }

/* hero */
.hero {
  padding: clamp(3rem, 10vw, 7rem) 1.25rem;
  text-align: center;
  background:
    radial-gradient(ellipse 70% 60% at 50% 0%, rgba(224, 164, 88, 0.13), transparent),
    var(--bg);
  border-bottom: 1px solid var(--line);
}
.hero-kicker {
  text-transform: uppercase; letter-spacing: 0.35em; font-size: 0.8rem;
  color: var(--accent); margin-bottom: 0.5rem;
}
.hero h1 { font-size: clamp(2.6rem, 8vw, 5rem); margin: 0; }
.hero-sub { max-width: 34rem; margin: 1rem auto 2rem; color: var(--ink-dim); font-size: 1.1rem; }
.hero-actions { display: flex; gap: 0.8rem; justify-content: center; flex-wrap: wrap; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.55rem 1.2rem; border-radius: 99px;
  border: 1px solid transparent; cursor: pointer;
  font-size: 0.95rem; font-weight: 600; font-family: var(--font-body);
  transition: all 0.15s ease;
}
.btn-primary { background: var(--accent); color: #1c1508; }
.btn-primary:hover { background: #ecb56e; text-decoration: none; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }
.btn-danger { background: transparent; color: var(--danger); border-color: var(--danger); }
.btn-danger:hover { background: var(--danger); color: var(--ink); }
.btn.sm { padding: 0.25rem 0.7rem; font-size: 0.85rem; }
.btn.disabled { opacity: 0.5; pointer-events: none; }
.linklike { background: none; border: none; color: var(--accent); cursor: pointer; font-size: 0.85rem; padding: 0; }

/* sections & grids */
.section { max-width: var(--maxw); margin: 0 auto; padding: 2.5rem 1.25rem; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; }
.more { font-size: 0.9rem; }
.grid { display: grid; gap: 1.4rem; }
.songs-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.albums-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }

/* song card */
.song-card {
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; color: var(--ink); display: flex; flex-direction: column;
  transition: transform 0.15s ease, border-color 0.15s ease;
}
.song-card:hover { transform: translateY(-3px); border-color: var(--accent-2); text-decoration: none; }
.song-card-art { position: relative; aspect-ratio: 1; background: var(--bg-3); }
.song-card-art img { width: 100%; height: 100%; object-fit: cover; }
.art-placeholder, .album-cover.placeholder, .playerbar-art.placeholder {
  display: flex; align-items: center; justify-content: center;
  width: 100%; height: 100%; color: var(--line); font-size: 3rem;
  background: linear-gradient(135deg, var(--bg-3), var(--bg-2));
}
.song-card-play {
  position: absolute; right: 0.7rem; bottom: 0.7rem;
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--accent); color: #1c1508; border: none;
  font-size: 1rem; cursor: pointer; opacity: 0;
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.song-card:hover .song-card-play { opacity: 1; }
.song-card-play:hover { transform: scale(1.08); }
.song-card-body { padding: 0.9rem 1rem 1.1rem; }
.song-card-body h3 { margin: 0 0 0.3rem; font-size: 1.15rem; }
.song-card-story { color: var(--ink-dim); font-size: 0.88rem; margin: 0 0 0.5rem; }

/* tags */
.tag-row { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-top: 0.4rem; }
.tag {
  font-size: 0.75rem; padding: 0.15rem 0.6rem; border-radius: 99px;
  background: var(--bg-3); color: var(--ink-dim);
  border: 1px solid var(--line); cursor: pointer;
}
.tag.on, .tag:hover { color: var(--accent); border-color: var(--accent-2); }
.tag-filter { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 1rem 0 1.5rem; }

/* album card */
.album-card { color: var(--ink); text-align: center; }
.album-card:hover { text-decoration: none; color: var(--accent); }
.album-card img, .album-cover { aspect-ratio: 1; width: 100%; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--line); }
.album-card-title { margin-top: 0.6rem; font-weight: 600; font-family: var(--font-display); }
.album-card-sub { font-size: 0.85rem; color: var(--ink-dim); }

/* page head */
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.search {
  background: var(--bg-2); border: 1px solid var(--line); color: var(--ink);
  border-radius: 99px; padding: 0.5rem 1.1rem; font-size: 0.95rem; min-width: 220px;
}
.search:focus { outline: none; border-color: var(--accent-2); }

/* song detail */
.song-hero { display: flex; gap: 2rem; align-items: flex-end; flex-wrap: wrap; margin-bottom: 1.5rem; }
.song-hero-art { width: 240px; border-radius: var(--radius); border: 1px solid var(--line); }
.song-writers { color: var(--ink-dim); font-style: italic; }
.tabs { display: flex; gap: 0.2rem; border-bottom: 1px solid var(--line); flex-wrap: wrap; margin: 1.5rem 0 0; }
.tab-btn {
  background: none; border: none; color: var(--ink-dim); cursor: pointer;
  padding: 0.6rem 1rem; font-size: 0.95rem; border-bottom: 2px solid transparent;
  font-family: var(--font-body);
}
.tab-btn.on { color: var(--accent); border-bottom-color: var(--accent); }
.tab-body { padding: 1.5rem 0; }
.prose { max-width: 44rem; white-space: pre-wrap; }
.lyrics, .chords {
  font-family: var(--font-mono); font-size: 0.95rem; line-height: 1.7;
  white-space: pre-wrap; background: var(--bg-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.5rem; max-width: 44rem; overflow-x: auto;
}

/* recording lists */
.rec-list { list-style: none; padding: 0; margin: 0; max-width: 44rem; }
.rec-item {
  display: flex; align-items: center; gap: 0.9rem;
  padding: 0.7rem 0.4rem; border-bottom: 1px solid var(--line);
}
.rec-meta { flex: 1; display: flex; flex-direction: column; }
.rec-title { font-weight: 600; }
.rec-kind { color: var(--ink-dim); font-size: 0.85rem; }
.dl { font-size: 1.1rem; }
.badge {
  font-style: normal; font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.08em;
  background: var(--bg-3); border: 1px solid var(--line); border-radius: 4px;
  padding: 0.1rem 0.4rem; margin-left: 0.5rem; color: var(--accent);
}
.badge.draft, .badge.pending { color: var(--ink-dim); }
.badge.published, .badge.approved { color: #8fbf7f; }
.badge.rejected { color: var(--danger); }

.perf-list { list-style: none; padding: 0; max-width: 44rem; }
.perf-list li { padding: 0.6rem 0; border-bottom: 1px solid var(--line); }

.art-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.2rem; }
.art-grid figure { margin: 0; }
.art-grid img { border-radius: var(--radius); border: 1px solid var(--line); }
.art-grid figcaption { font-size: 0.85rem; color: var(--ink-dim); margin-top: 0.4rem; }

.rights { max-width: 34rem; }
.rights dt { color: var(--ink-dim); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; margin-top: 0.8rem; }
.rights dd { margin: 0.1rem 0 0; }

/* track list */
.track-list { list-style: none; padding: 0; max-width: 44rem; counter-reset: track; }
.track-list li { display: flex; align-items: center; gap: 0.8rem; padding: 0.55rem 0.3rem; border-bottom: 1px solid var(--line); }
.track-title { font-weight: 500; }

/* club */
.club-hero { max-width: 44rem; margin-bottom: 2rem; }
.club-teaser { text-align: center; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 3rem 1.5rem; margin: 2rem auto; }
.club-teaser p { max-width: 36rem; margin: 0.8rem auto 1.5rem; color: var(--ink-dim); }
.welcome { color: var(--accent); font-family: var(--font-display); font-size: 1.2rem; }

/* forms */
.auth-form, .contribute-form {
  max-width: 26rem; background: var(--bg-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.5rem; display: flex; flex-direction: column; gap: 0.8rem;
}
.contribute-form { max-width: 34rem; }
.auth-tabs { display: flex; gap: 0.4rem; }
.auth-tabs button {
  flex: 1; background: none; border: 1px solid var(--line); color: var(--ink-dim);
  padding: 0.5rem; border-radius: 6px; cursor: pointer;
}
.auth-tabs button.on { border-color: var(--accent); color: var(--accent); }
input, textarea, select {
  background: var(--bg); border: 1px solid var(--line); color: var(--ink);
  border-radius: 6px; padding: 0.55rem 0.8rem; font-size: 0.95rem; font-family: var(--font-body);
  width: 100%;
}
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--accent-2); }
label { display: flex; flex-direction: column; gap: 0.25rem; font-size: 0.85rem; color: var(--ink-dim); flex: 1; }
.form-msg { color: var(--accent); font-size: 0.9rem; }
.form-row { display: flex; gap: 0.8rem; flex-wrap: wrap; margin-bottom: 0.8rem; }
.form-row > * { flex: 1; min-width: 180px; }
.form-actions { display: flex; align-items: center; gap: 1rem; margin-top: 0.8rem; }
.check { flex-direction: row; align-items: center; gap: 0.5rem; }
.check input { width: auto; }

/* admin */
.admin-nav { display: flex; gap: 0.5rem; margin-bottom: 1.5rem; flex-wrap: wrap; }
.admin-nav a {
  padding: 0.4rem 1rem; border-radius: 99px; border: 1px solid var(--line); color: var(--ink-dim);
}
.admin-nav a.on { border-color: var(--accent); color: var(--accent); }
.admin-nav a:hover { text-decoration: none; color: var(--ink); }
.panel { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 1.2rem; overflow: hidden; }
.panel-head {
  display: flex; justify-content: space-between; align-items: center; width: 100%;
  background: none; border: none; color: var(--ink); cursor: pointer;
  padding: 0.9rem 1.2rem; text-align: left;
}
.panel-head.static { cursor: default; }
.panel-head h2 { margin: 0; font-size: 1.1rem; }
.panel-body, .quick-add { padding: 0 1.2rem 1.2rem; }
.quick-add textarea { font-family: var(--font-mono); font-size: 0.9rem; }
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th {
  text-align: left; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--ink-dim); padding: 0.6rem 1.2rem; border-bottom: 1px solid var(--line);
}
.admin-table td { padding: 0.7rem 1.2rem; border-bottom: 1px solid var(--line); }
.admin-table tbody tr { cursor: pointer; }
.admin-table tbody tr:hover { background: var(--bg-3); }
.admin-list { list-style: none; padding: 0; }
.admin-list li {
  display: flex; align-items: center; gap: 0.8rem; flex-wrap: wrap;
  padding: 0.7rem 0.2rem; border-bottom: 1px solid var(--line);
}
.admin-list-main { flex: 1; min-width: 250px; }
.admin-list audio { height: 32px; max-width: 260px; }
.add-inline, .row-form { display: flex; gap: 0.6rem; flex-wrap: wrap; margin: 0.8rem 0; }
.add-inline input { max-width: 260px; }
.row-form input, .row-form select { flex: 1; min-width: 140px; max-width: 240px; }
.chip-row { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.chip {
  display: inline-flex; align-items: center; gap: 0.4rem;
  background: var(--bg-3); border: 1px solid var(--line); border-radius: 99px;
  padding: 0.25rem 0.8rem; font-size: 0.9rem;
}
.chip button { background: none; border: none; color: var(--ink-dim); cursor: pointer; font-size: 1rem; }
.chip button:hover { color: var(--danger); }
.editor-head { margin-bottom: 1.5rem; }
.editor-actions { display: flex; gap: 0.6rem; align-items: center; flex-wrap: wrap; }
.editor-actions select { width: auto; }
.ia-upload { display: flex; align-items: center; gap: 0.8rem; margin-top: 0.8rem; flex-wrap: wrap; }

/* player bar */
.playerbar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 100;
  display: grid; grid-template-columns: 1fr auto 1.2fr; gap: 1.2rem; align-items: center;
  background: color-mix(in srgb, var(--bg-2) 94%, transparent);
  backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
  padding: 0.6rem 1.2rem;
}
.playerbar-info { display: flex; align-items: center; gap: 0.8rem; min-width: 0; }
.playerbar-art { width: 48px; height: 48px; border-radius: 6px; object-fit: cover; }
.playerbar-titles { min-width: 0; }
.playerbar-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.playerbar-sub { font-size: 0.8rem; color: var(--ink-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.playerbar-controls { display: flex; gap: 0.4rem; align-items: center; }
.pbtn {
  background: none; border: 1px solid var(--line); color: var(--ink);
  width: 36px; height: 36px; border-radius: 50%; cursor: pointer; font-size: 0.85rem;
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.pbtn:hover { border-color: var(--accent); color: var(--accent); }
.pbtn-main { width: 44px; height: 44px; background: var(--accent); color: #1c1508; border: none; font-size: 1rem; }
.pbtn-main:hover { color: #1c1508; background: #ecb56e; }
.playerbar-seek { display: flex; align-items: center; gap: 0.6rem; }
.playerbar-seek input[type="range"] { flex: 1; accent-color: var(--accent); padding: 0; }
.ptime { font-size: 0.75rem; color: var(--ink-dim); font-variant-numeric: tabular-nums; }

/* footer */
.site-footer {
  border-top: 1px solid var(--line); color: var(--ink-dim);
  text-align: center; padding: 2rem 1rem 8rem; font-size: 0.85rem;
}

@media (max-width: 720px) {
  .menu-toggle { display: block; }
  .site-header nav {
    display: none; position: absolute; top: 100%; right: 0; left: 0;
    flex-direction: column; background: var(--bg-2); padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--line);
  }
  .site-header nav.open { display: flex; }
  .playerbar { grid-template-columns: 1fr auto; }
  .playerbar-seek { display: none; }
  .song-hero-art { width: 100%; max-width: 320px; }
}

/* ---- MP3 import dropzone ---- */
.dropzone {
  border: 2px dashed var(--line, #3a332a);
  border-radius: 12px;
  padding: 2.2rem 1.5rem;
  text-align: center;
  margin: 1rem;
  transition: border-color .15s, background .15s;
}
.dropzone.over { border-color: var(--accent, #e0a458); background: rgba(224,164,88,.06); }
.dropzone p { margin: .3rem 0 .8rem; }
.import-list { list-style: none; margin: 0; padding: .5rem 1rem 1rem; }
.import-row {
  display: flex; align-items: center; gap: .9rem;
  padding: .7rem .4rem; border-bottom: 1px solid var(--line, #3a332a);
}
.import-row:last-child { border-bottom: none; }
.import-row img, .import-thumb {
  width: 48px; height: 48px; border-radius: 8px; object-fit: cover; flex: none;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,.06); font-size: 1.3rem;
}
.import-info { display: flex; flex-direction: column; gap: .1rem; min-width: 0; flex: 1; }
.import-info strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.import-msg { font-size: .82rem; opacity: .8; }
.import-msg.done { color: #7fc98b; }
.import-msg.warn { color: #e0a458; }
.import-msg.error { color: #e07070; }
.import-opt { display: block; margin-top: .8rem; cursor: pointer; }
.label-row { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.label-row .form-msg { font-size: .78rem; }
.btn.small { padding: .15rem .6rem; font-size: .78rem; }

/* ---- Song detail: lyrics left, rail right ---- */
.song-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2.2rem;
  align-items: start;
  margin-top: 1.6rem;
}
.col-title {
  font-size: .8rem; letter-spacing: .12em; text-transform: uppercase;
  color: var(--accent, #e0a458); margin: 0 0 .8rem;
}
.song-main section { margin-bottom: 2rem; }
.lyrics-fmt { font-size: 1.02rem; line-height: 1.75; }
.lyric-section { margin-bottom: 1.4rem; }
.lyric-section pre {
  margin: 0; white-space: pre-wrap; font-family: inherit;
  background: none; border: none; padding: 0;
}
.lyric-label {
  display: inline-block; font-size: .72rem; letter-spacing: .14em;
  text-transform: uppercase; opacity: .55; margin-bottom: .3rem;
}
.song-rail { display: flex; flex-direction: column; gap: 1.2rem; position: sticky; top: 1rem; }
.rail-card {
  background: rgba(255,255,255,.03);
  border: 1px solid var(--line, #3a332a);
  border-radius: 12px; padding: 1rem 1.1rem;
}
.rail-card h3 {
  margin: 0 0 .7rem; font-size: .8rem; letter-spacing: .12em;
  text-transform: uppercase; color: var(--accent, #e0a458);
}
.rail-card .rec-list.compact { margin: 0; padding: 0; }
.rail-card .rec-item { padding: .45rem 0; }
.rail-chords {
  max-height: 340px; overflow: auto; font-size: .82rem;
  background: none; border: none; padding: 0; margin: 0; white-space: pre-wrap;
}
.rec-style { display: block; }
.song-extras { margin-top: 2.5rem; display: grid; gap: 2rem; }
@media (max-width: 860px) {
  .song-layout { grid-template-columns: 1fr; }
  .song-rail { position: static; }
}
.auth-form.inpage { max-width: 420px; margin: 0; padding: 1rem 1.1rem; }
.stage-area { padding: 0 1rem 1rem; }
.stage-actions { align-items: center; margin-top: .6rem; }
.stage-actions select { flex: 1; }
