/* ══════════════════════════════════════════
   SERENITY RADIO — moat2.css
   Account section, upgrade banner, teacher callout
   ══════════════════════════════════════════ */

/* ── Account Section ── */
#account-section { margin: 1.5rem 0; }

/* Guest card */
.account-guest-card {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; flex-wrap: wrap;
  background: var(--bg2); border: 1px solid rgba(122,158,126,.25);
  border-radius: 16px; padding: 1.25rem 1.5rem;
  animation: fadeUp .5s .1s ease both;
}
.ag-left { display: flex; align-items: center; gap: 1rem; }
.ag-icon {
  width: 42px; height: 42px; border-radius: 50%;
  background: linear-gradient(135deg, rgba(122,158,126,.3), rgba(107,127,168,.2));
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; flex-shrink: 0;
}
.ag-title { font-size: 15px; font-weight: 500; margin-bottom: 3px; }
.ag-sub { font-size: 13px; color: var(--text-muted); }
.ag-btn {
  font-family: 'DM Sans', sans-serif; font-size: 14px; font-weight: 500;
  padding: 10px 22px; border-radius: 50px;
  background: var(--sage); color: #fff; border: none; cursor: pointer;
  white-space: nowrap; transition: opacity .2s, transform .15s;
  flex-shrink: 0;
}
.ag-btn:hover { opacity: .88; transform: translateY(-1px); }

/* User card */
.account-user-card {
  background: var(--bg2); border: 1px solid rgba(122,158,126,.2);
  border-radius: 16px; padding: 1.25rem 1.5rem;
  animation: fadeUp .4s ease both;
}
.au-row { display: flex; align-items: center; gap: 12px; margin-bottom: 1rem; }
.au-avatar {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--sage); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; font-weight: 600; flex-shrink: 0;
}
.au-info { flex: 1; min-width: 0; }
.au-name { font-size: 15px; font-weight: 500; }
.au-email { font-size: 12px; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.au-plan-badge {
  padding: 3px 10px; border-radius: 20px; font-size: 11px; font-weight: 600;
  letter-spacing: .04em; flex-shrink: 0;
}
.au-actions {
  display: flex; gap: 8px; flex-wrap: wrap;
}
.au-action-btn {
  font-family: 'DM Sans', sans-serif; font-size: 13px;
  padding: 7px 14px; border-radius: 50px;
  background: var(--bg3); border: 1px solid var(--border);
  color: var(--text); cursor: pointer; transition: border-color .2s, background .2s;
}
.au-action-btn:hover { border-color: rgba(122,158,126,.4); background: rgba(122,158,126,.08); }
.au-upgrade-btn { border-color: rgba(212,168,67,.3); color: #d4a843; }
.au-upgrade-btn:hover { background: rgba(212,168,67,.1); border-color: #d4a843; }

/* ── Upgrade Banner ── */
.upgrade-banner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; flex-wrap: wrap;
  background: linear-gradient(135deg, rgba(212,168,67,.08), rgba(122,158,126,.08));
  border: 1px solid rgba(212,168,67,.2);
  border-radius: 16px; padding: 1.25rem 1.5rem; margin: 1.5rem 0;
  animation: fadeUp .5s .15s ease both;
}
.ub-left { flex: 1; min-width: 200px; }
.ub-title { font-size: 15px; font-weight: 500; color: #d4a843; margin-bottom: .5rem; }
.ub-feats { display: flex; flex-wrap: wrap; gap: 8px; }
.ub-feats span { font-size: 12px; color: var(--text-muted); background: rgba(255,255,255,.04); padding: 3px 10px; border-radius: 20px; }
.ub-right { flex-shrink: 0; }
.ub-prices { display: flex; gap: 8px; }
.ub-plan-btn {
  font-family: 'DM Sans', sans-serif; font-size: 13px; line-height: 1.4;
  padding: 10px 16px; border-radius: 12px; text-align: center;
  background: var(--bg3); border: 1px solid rgba(212,168,67,.3);
  color: var(--text); cursor: pointer; transition: background .2s, border-color .2s;
}
.ub-plan-btn strong { font-size: 1.3rem; color: #d4a843; display: block; }
.ub-plan-btn span { font-size: 11px; color: var(--text-muted); }
.ub-plan-btn:hover { background: rgba(212,168,67,.1); border-color: #d4a843; }
.ub-plan-btn.featured {
  background: rgba(212,168,67,.1); border-color: rgba(212,168,67,.5);
}
.ub-plan-btn.featured strong { color: #e8c560; }

/* ── Teacher Callout ── */
.teacher-callout {
  display: flex; align-items: center; gap: 1rem; flex-wrap: wrap;
  background: var(--bg2);
  border: 1px solid rgba(107,127,168,.2);
  border-left: 3px solid var(--dusk, #6b7fa8);
  border-radius: 0 16px 16px 0; padding: 1.25rem 1.5rem; margin: 1.5rem 0;
  animation: fadeUp .5s .2s ease both;
}
.tc-emoji { font-size: 2rem; flex-shrink: 0; }
.tc-body { flex: 1; min-width: 180px; }
.tc-title { font-size: 15px; font-weight: 500; margin-bottom: 4px; }
.tc-sub { font-size: 13px; color: var(--text-muted); line-height: 1.5; }
.tc-btn {
  display: inline-block; font-family: 'DM Sans', sans-serif;
  font-size: 13px; font-weight: 500;
  padding: 9px 20px; border-radius: 50px;
  background: rgba(107,127,168,.15); border: 1px solid rgba(107,127,168,.3);
  color: var(--dusk-light, #c2cde0); text-decoration: none;
  white-space: nowrap; flex-shrink: 0;
  transition: background .2s, border-color .2s;
}
.tc-btn:hover { background: rgba(107,127,168,.25); border-color: rgba(107,127,168,.6); }

@media (max-width: 520px) {
  .account-guest-card { flex-direction: column; align-items: flex-start; }
  .ag-btn { width: 100%; text-align: center; }
  .upgrade-banner { flex-direction: column; }
  .ub-prices { width: 100%; }
  .ub-plan-btn { flex: 1; }
  .teacher-callout { flex-direction: column; }
  .tc-btn { width: 100%; text-align: center; }
}

/* ══════════════════════════════════════════
   TRACKLIST
   ══════════════════════════════════════════ */
.tracklist-grid {
  display: flex; flex-direction: column; gap: 2px;
  margin-bottom: 1.5rem;
}
.tl-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: 12px;
  cursor: pointer; transition: background .15s;
  border: 1px solid transparent;
}
.tl-row:hover { background: var(--bg2); border-color: var(--border); }
.tl-active {
  background: rgba(122,158,126,.1) !important;
  border-color: rgba(122,158,126,.3) !important;
}
.tl-num {
  width: 24px; text-align: center; font-size: 12px;
  color: var(--text-muted); flex-shrink: 0;
}
.tl-active .tl-num { color: var(--sage-l); font-weight: 700; }
.tl-info { flex: 1; min-width: 0; }
.tl-title {
  font-size: 14px; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}
.tl-active .tl-title { color: var(--sage-l); }
.tl-artist { font-size: 12px; color: var(--text-muted); }
.tl-dur { font-size: 12px; color: var(--text-muted); min-width: 36px; text-align: right; }
.tl-fav {
  background: none; border: none; cursor: pointer;
  color: var(--text-muted); font-size: 16px; padding: 4px 6px;
  border-radius: 6px; line-height: 1; transition: color .2s;
  flex-shrink: 0; opacity: 0;
}
.tl-row:hover .tl-fav { opacity: 1; }
.tl-fav:hover { color: #c96a6a; }

/* ══════════════════════════════════════════
   SCORE HISTORY CHART BUTTON
   ══════════════════════════════════════════ */
.score-history-btn {
  display: block; width: 100%; margin-top: .75rem;
  padding: 8px; border-radius: 8px; border: 1px solid var(--border);
  background: transparent; color: var(--text-muted);
  font-size: 12px; cursor: pointer; font-family: inherit;
  transition: border-color .2s, color .2s;
}
.score-history-btn:hover { border-color: var(--sage); color: var(--sage-l); }

/* ══════════════════════════════════════════
   MOBILE — global fixes
   ══════════════════════════════════════════ */
@media (max-width: 480px) {
  /* Header */
  .header-actions { gap: 6px; }
  .header-actions .btn { font-size: 11px; padding: 6px 10px; }
  #auth-area .auth-user { padding: 4px 8px; }
  #auth-area .auth-name { display: none; }

  /* Player card */
  .player-card { padding: 1.25rem 1rem; }
  .controls { gap: .6rem; }
  .play-btn { width: 46px; height: 46px; }

  /* Channel tabs */
  .ch-tab { font-size: 12px; padding: 6px 10px; }

  /* Account + upgrade */
  .account-guest-card { flex-direction: column; gap: .75rem; }
  .ag-left { gap: .75rem; }
  .ag-btn { width: 100%; text-align: center; }
  .upgrade-banner { flex-direction: column; }
  .ub-prices { flex-direction: column; }
  .ub-plan-btn { width: 100%; }
  .teacher-callout { flex-direction: column; gap: .75rem; }
  .tc-btn { width: 100%; text-align: center; padding: 10px; }

  /* Tracklist */
  .tl-fav { opacity: 1; } /* always show on mobile */
  .tl-dur { display: none; }
  #track-search { width: 110px; font-size: 12px; }

  /* Section title with search */
  .section-title { font-size: 1.1rem; gap: 6px; flex-wrap: wrap; }

  /* Stats strip */
  .stats-strip { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .stat-value { font-size: 1.4rem; }

  /* DJ card */
  .dj-card { padding: 1rem; gap: .75rem; }
  .dj-avatar { width: 36px; height: 36px; font-size: 16px; }
}

/* Score row inside account card */
.au-score-row {
  align-items: center; gap: 12px;
  background: rgba(122,158,126,.06); border-radius: 12px;
  padding: .75rem 1rem; margin-bottom: .75rem;
  flex-wrap: wrap;
}
.au-score-circle {
  width: 44px; height: 44px; border-radius: 50%;
  background: #555; color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; font-weight: 700; flex-shrink: 0;
  transition: background .4s;
}
.au-score-label { font-size: 13px; font-weight: 500; }
.au-score-sub   { font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.au-score-info  { flex: 1; min-width: 100px; }

/* Schedule items now clickable */
.schedule-item { cursor: pointer; }
.schedule-item:hover { border-color: rgba(122,158,126,.4) !important; }
