/* =========================================================================
   YARDWAVE — Platform Stylesheet
   =========================================================================
   Mood-first. Jamaica-rooted. Dark by default.
   Colors: black foundation, gold accents, mood-specific highlights.
   Typography: clean, modern, with patois warmth.
   ========================================================================= */

/* ---------------------------------------------------------------------------
   CSS Custom Properties
   --------------------------------------------------------------------------- */
:root {
  /* Foundation */
  --bg-primary: #0A0A0A;
  --bg-secondary: #111111;
  --bg-card: #161616;
  --bg-hover: #1A1A1A;
  --bg-input: #1E1E1E;

  /* Text */
  --text-primary: #F0F0F0;
  --text-secondary: #999999;
  --text-muted: #666666;
  --text-accent: #C9A84C;

  /* Brand */
  --gold: #C9A84C;
  --gold-dim: #8A7333;
  --red: #D64045;
  --green: #1DB954;

  /* Mood colors */
  --mood-1: #4A9ECC;  /* CHARGED */
  --mood-2: #C9A84C;  /* SMOOTH */
  --mood-3: #1DB954;  /* LIFTED */
  --mood-4: #D64045;  /* RAW */
  --mood-5: #8A7ACC;  /* MEDITATIVE */
  --mood-6: #C9A84C;  /* VIBING */
  --mood-7: #888888;  /* LATE HOURS */

  /* Mood backgrounds */
  --mood-bg-1: #0D1B2A;
  --mood-bg-2: #1A0A00;
  --mood-bg-3: #0A1A0D;
  --mood-bg-4: #1A0A12;
  --mood-bg-5: #0A0A1A;
  --mood-bg-6: #1A1500;
  --mood-bg-7: #0A0808;

  /* Layout */
  --max-width: 1200px;
  --radius: 8px;
  --radius-lg: 16px;

  /* Transitions */
  --ease: cubic-bezier(0.25, 0.1, 0.25, 1);
}


/* ---------------------------------------------------------------------------
   Reset & Base
   --------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
}

a {
  color: var(--gold);
  text-decoration: none;
  transition: color 0.2s var(--ease);
}
a:hover { color: var(--text-primary); }

img { max-width: 100%; display: block; }

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

input, select {
  font-family: inherit;
  font-size: inherit;
}


/* ---------------------------------------------------------------------------
   Typography
   --------------------------------------------------------------------------- */
h1, h2, h3, h4 {
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.5rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.5rem); }

.text-gold { color: var(--gold); }
.text-muted { color: var(--text-muted); }
.text-patois {
  font-style: italic;
  color: var(--text-secondary);
  font-size: 0.9em;
}


/* ---------------------------------------------------------------------------
   Layout
   --------------------------------------------------------------------------- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.section {
  padding: 80px 0;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

@media (max-width: 768px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .section { padding: 48px 0; }
}


/* ---------------------------------------------------------------------------
   Navigation
   --------------------------------------------------------------------------- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(10, 10, 10, 0.92);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  color: var(--gold);
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  gap: 32px;
  align-items: center;
  list-style: none;
}

.nav-links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover,
.nav-links a.active { color: var(--text-primary); }

.nav-cta {
  background: var(--gold);
  color: #000;
  padding: 8px 20px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.85rem;
  transition: background 0.2s;
}
.nav-cta:hover {
  background: var(--text-primary);
  color: #000;
}

@media (max-width: 768px) {
  .nav-links { gap: 16px; }
  .nav-links .hide-mobile { display: none; }
}


/* ---------------------------------------------------------------------------
   Hero Section
   --------------------------------------------------------------------------- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 24px 80px;
  background: radial-gradient(ellipse at 50% 30%, rgba(201, 168, 76, 0.08) 0%, transparent 60%);
}

.hero h1 {
  margin-bottom: 16px;
}

.hero .subtitle {
  font-size: clamp(1rem, 2vw, 1.3rem);
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 40px;
}

.hero .patois-tagline {
  font-size: 1.1rem;
  color: var(--gold);
  font-style: italic;
  margin-bottom: 40px;
}


/* ---------------------------------------------------------------------------
   Buttons
   --------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.2s var(--ease);
}

.btn-primary {
  background: var(--gold);
  color: #000;
}
.btn-primary:hover {
  background: var(--text-primary);
  color: #000;
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.15);
}
.btn-secondary:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.btn-sm {
  padding: 8px 20px;
  font-size: 0.85rem;
}


/* ---------------------------------------------------------------------------
   Mood Station Cards
   --------------------------------------------------------------------------- */
.mood-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  padding: 20px 0;
}

.mood-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 32px;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s var(--ease);
  border: 1px solid rgba(255, 255, 255, 0.04);
}

.mood-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  opacity: 0.4;
  transition: opacity 0.3s;
  z-index: 0;
}

.mood-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.1);
}
.mood-card:hover::before { opacity: 0.7; }

.mood-card[data-mood="1"]::before { background: var(--mood-bg-1); }
.mood-card[data-mood="2"]::before { background: var(--mood-bg-2); }
.mood-card[data-mood="3"]::before { background: var(--mood-bg-3); }
.mood-card[data-mood="4"]::before { background: var(--mood-bg-4); }
.mood-card[data-mood="5"]::before { background: var(--mood-bg-5); }
.mood-card[data-mood="6"]::before { background: var(--mood-bg-6); }
.mood-card[data-mood="7"]::before { background: var(--mood-bg-7); }

.mood-card > * { position: relative; z-index: 1; }

.mood-number {
  font-size: 3rem;
  font-weight: 800;
  opacity: 0.15;
  position: absolute;
  top: 16px;
  right: 20px;
  z-index: 1;
}

.mood-name {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.mood-card[data-mood="1"] .mood-name { color: var(--mood-1); }
.mood-card[data-mood="2"] .mood-name { color: var(--mood-2); }
.mood-card[data-mood="3"] .mood-name { color: var(--mood-3); }
.mood-card[data-mood="4"] .mood-name { color: var(--mood-4); }
.mood-card[data-mood="5"] .mood-name { color: var(--mood-5); }
.mood-card[data-mood="6"] .mood-name { color: var(--mood-6); }
.mood-card[data-mood="7"] .mood-name { color: var(--mood-7); }

.mood-patois {
  font-style: italic;
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 12px;
}

.mood-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 16px;
}

.mood-meta {
  display: flex;
  gap: 16px;
  font-size: 0.8rem;
  color: var(--text-muted);
}


/* ---------------------------------------------------------------------------
   Track List
   --------------------------------------------------------------------------- */
.track-list {
  list-style: none;
}

.track-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border-radius: var(--radius);
  transition: background 0.2s;
  cursor: pointer;
}

.track-item:hover {
  background: var(--bg-hover);
}

.track-item.playing {
  background: var(--bg-hover);
}

.track-number {
  font-size: 0.85rem;
  color: var(--text-muted);
  width: 32px;
  text-align: center;
  flex-shrink: 0;
}

.track-play-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-input);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.2s;
}
.track-play-btn:hover { background: var(--gold); }
.track-play-btn:hover svg { fill: #000; }
.track-play-btn svg {
  width: 14px;
  height: 14px;
  fill: var(--text-primary);
}

.track-info {
  flex: 1;
  min-width: 0;
}

.track-title {
  font-weight: 600;
  font-size: 0.95rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.track-artist {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.track-mood-tag {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.06);
}

.track-duration {
  font-size: 0.8rem;
  color: var(--text-muted);
  flex-shrink: 0;
}


/* ---------------------------------------------------------------------------
   Audio Player Bar
   --------------------------------------------------------------------------- */
.player-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: rgba(22, 22, 22, 0.95);
  backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  z-index: 200;
  display: none;
  align-items: center;
  padding: 0 24px;
}

.player-bar.active { display: flex; }

.player-track-info {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 250px;
  flex-shrink: 0;
}

.player-track-title {
  font-weight: 600;
  font-size: 0.9rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-track-mood {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.player-controls {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.player-buttons {
  display: flex;
  align-items: center;
  gap: 24px;
}

.player-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s;
}
.player-btn svg {
  width: 16px;
  height: 16px;
  fill: var(--text-primary);
}
.player-btn:hover svg { fill: var(--gold); }

.player-btn-main {
  width: 42px;
  height: 42px;
  background: var(--gold);
  border-radius: 50%;
}
.player-btn-main svg { fill: #000; width: 18px; height: 18px; }
.player-btn-main:hover { background: var(--text-primary); }

.player-progress {
  width: 100%;
  max-width: 600px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.player-time {
  font-size: 0.7rem;
  color: var(--text-muted);
  width: 40px;
  text-align: center;
}

.progress-bar {
  flex: 1;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  cursor: pointer;
  position: relative;
}

.progress-fill {
  height: 100%;
  background: var(--gold);
  border-radius: 2px;
  width: 0%;
  transition: width 0.1s linear;
}

.progress-bar:hover .progress-fill { background: var(--text-primary); }
.progress-bar:hover { height: 6px; }

.player-volume {
  width: 150px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.volume-slider {
  width: 80px;
  height: 4px;
  -webkit-appearance: none;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  outline: none;
}

.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--text-primary);
  cursor: pointer;
}

@media (max-width: 768px) {
  .player-track-info { width: 120px; }
  .player-volume { display: none; }
}


/* ---------------------------------------------------------------------------
   Auth / Login Forms
   --------------------------------------------------------------------------- */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.auth-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 48px;
  width: 100%;
  max-width: 420px;
  border: 1px solid rgba(255, 255, 255, 0.04);
}

.auth-card h2 {
  text-align: center;
  margin-bottom: 8px;
}

.auth-card .auth-subtitle {
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 32px;
}

.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.form-input {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-input);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-size: 0.95rem;
  transition: border-color 0.2s;
  outline: none;
}

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

.form-input::placeholder {
  color: var(--text-muted);
}

.form-error {
  color: var(--red);
  font-size: 0.8rem;
  margin-top: 4px;
  display: none;
}

.form-error.visible { display: block; }

.auth-submit {
  width: 100%;
  margin-top: 8px;
}

.auth-footer {
  text-align: center;
  margin-top: 24px;
  font-size: 0.85rem;
  color: var(--text-muted);
}


/* ---------------------------------------------------------------------------
   Subscribe / Pricing
   --------------------------------------------------------------------------- */
.pricing-cards {
  display: flex;
  gap: 24px;
  justify-content: center;
  flex-wrap: wrap;
}

.pricing-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  width: 320px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.04);
  transition: border-color 0.3s;
}

.pricing-card.featured {
  border-color: var(--gold);
}

.pricing-card .plan-name {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.pricing-card .plan-price {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 4px;
}

.pricing-card .plan-period {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.pricing-card .plan-savings {
  color: var(--green);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 24px;
}

.plan-features {
  list-style: none;
  text-align: left;
  margin-bottom: 32px;
}

.plan-features li {
  padding: 8px 0;
  font-size: 0.9rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.plan-features li::before {
  content: '\2713';
  color: var(--gold);
  font-weight: 700;
}


/* ---------------------------------------------------------------------------
   Mood Station View (inner app)
   --------------------------------------------------------------------------- */
.station-header {
  padding: 80px 0 40px;
  text-align: center;
}

.station-header .mood-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 6px 16px;
  border-radius: 100px;
  margin-bottom: 16px;
}

.station-track-count {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 8px;
}


/* ---------------------------------------------------------------------------
   Locked / Subscribe CTA
   --------------------------------------------------------------------------- */
.lock-overlay {
  text-align: center;
  padding: 60px 24px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  margin: 40px 0;
}

.lock-overlay h3 {
  margin-bottom: 8px;
}

.lock-overlay p {
  color: var(--text-secondary);
  margin-bottom: 24px;
}


/* ---------------------------------------------------------------------------
   Footer
   --------------------------------------------------------------------------- */
.footer {
  padding: 48px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  text-align: center;
  margin-top: auto;
}

.footer-brand {
  font-weight: 800;
  letter-spacing: 0.15em;
  color: var(--gold);
  font-size: 1rem;
  margin-bottom: 8px;
}

.footer-tagline {
  font-style: italic;
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 16px;
}

.footer-links {
  display: flex;
  gap: 24px;
  justify-content: center;
  list-style: none;
}

.footer-links a {
  color: var(--text-muted);
  font-size: 0.8rem;
}
.footer-links a:hover { color: var(--text-primary); }

.footer-copy {
  color: var(--text-muted);
  font-size: 0.75rem;
  margin-top: 24px;
}


/* ---------------------------------------------------------------------------
   Utilities
   --------------------------------------------------------------------------- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.hidden { display: none !important; }

.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }
.mb-4 { margin-bottom: 32px; }

.text-center { text-align: center; }

.fade-in {
  animation: fadeIn 0.4s var(--ease);
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Loading spinner */
.spinner {
  width: 24px;
  height: 24px;
  border: 3px solid rgba(255, 255, 255, 0.1);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Toast notification */
.toast {
  position: fixed;
  bottom: 100px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius);
  padding: 12px 24px;
  font-size: 0.9rem;
  z-index: 300;
  animation: toastIn 0.3s var(--ease);
}

@keyframes toastIn {
  from { opacity: 0; transform: translateX(-50%) translateY(10px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}
