/* =========================================================
   ESTILOS GENERALES RAÍZ SONORA
   ========================================================= */

*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  --bg-main: #020617;         /* fondo dark galaxia */
  --bg-card: rgba(15, 23, 42, 0.95);
  --accent-green: #22c55e;
  --accent-teal: #14b8a6;
  --accent-blue: #3b82f6;
  --accent-purple: #a855f7;
  --text-main: #e5e7eb;
  --text-soft: #9ca3af;
  --border-soft: rgba(148, 163, 184, 0.35);
  --radius-main: 1.25rem;
  --shadow-main: 0 25px 60px rgba(15, 23, 42, 0.9);
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    Roboto, sans-serif;
  background:
    radial-gradient(circle at top, rgba(56, 189, 248, 0.15), transparent 60%),
    radial-gradient(circle at bottom, rgba(168, 85, 247, 0.18), #020617);
  color: var(--text-main);
  line-height: 1.5;
}

/* Contenedor principal centrado */
.page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.25rem 1rem 2.5rem;
}

/* Enlaces */
a {
  color: var(--accent-green);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* =========================================================
   HEADER
   ========================================================= */

.main-header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding-bottom: 0.6rem;
  backdrop-filter: blur(16px);
}

/* Línea de frecuencias arriba */
.frequency-bar {
  height: 2px;
  width: 100%;
  background: linear-gradient(
    90deg,
    #22c55e,
    #3b82f6,
    #a855f7,
    #22c55e
  );
  background-size: 200% 100%;
  animation: freq-move 8s linear infinite;
  border-radius: 999px;
  margin-bottom: 0.5rem;
}

@keyframes freq-move {
  0% {
    background-position: 0 0;
  }
  100% {
    background-position: 200% 0;
  }
}

/* Logo + idioma */
.logo-area {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo-circle {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  letter-spacing: 0.06em;
  background: radial-gradient(circle at top left, #22c55e, #0f172a);
  color: #020617;
  box-shadow: 0 10px 26px rgba(34, 197, 94, 0.6);
}

/* Switch de idioma */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.85rem;
}

.lang {
  cursor: pointer;
  color: var(--text-soft);
}

.lang.active {
  color: var(--accent-green);
  font-weight: 600;
}

.lang-separator {
  opacity: 0.6;
}

/* =========================================================
   SECCIONES Y CARDS
   ========================================================= */

.main-content {
  margin-top: 1.2rem;
}

/* Hero con imagen de fondo */
.hero {
  position: relative;
  margin-bottom: 1.5rem;
  padding: 2.2rem 1.6rem;
  border-radius: var(--radius-main);
  overflow: hidden;
  box-shadow: var(--shadow-main);
  background-image:
    linear-gradient(
      135deg,
      rgba(15, 23, 42, 0.9),
      rgba(15, 23, 42, 0.85),
      rgba(12, 148, 136, 0.6)
    ),
    url("img/header-bg.jpg");
  background-size: cover;
  background-position: center;
  border: 1px solid rgba(148, 163, 184, 0.45);
}

.hero h1 {
  margin: 0 0 0.7rem;
  font-size: 2.1rem;
}

.hero p {
  margin: 0 0 0.6rem;
  color: var(--text-soft);
  max-width: 650px;
}

/* Secciones generales */
.section {
  margin-bottom: 1.5rem;
}

.card {
  background: var(--bg-card);
  border-radius: var(--radius-main);
  padding: 1.5rem 1.4rem;
  box-shadow: var(--shadow-main);
  border: 1px solid var(--border-soft);
}

/* Títulos */
h1,
h2,
h3 {
  font-weight: 700;
  margin-top: 0;
}

h2 {
  font-size: 1.5rem;
  margin-bottom: 0.6rem;
}

h3 {
  font-size: 1.1rem;
  margin-bottom: 0.3rem;
}

p {
  margin: 0 0 0.55rem;
  color: var(--text-soft);
}

/* Botón principal */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.8rem;
  padding: 0.55rem 1.3rem;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, #22c55e, #14b8a6);
  color: #020617;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 12px 30px rgba(34, 197, 94, 0.55);
  transition: transform 0.12s ease, box-shadow 0.12s ease, opacity 0.12s ease;
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 40px rgba(34, 197, 94, 0.7);
  opacity: 0.97;
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 8px 18px rgba(34, 197, 94, 0.65);
}

/* =========================================================
   FRECUENCIAS
   ========================================================= */

.freq-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.freq-card {
  background: radial-gradient(circle at top, rgba(37, 99, 235, 0.35), #020617);
  border-radius: 0.9rem;
  padding: 0.9rem 0.9rem 0.85rem;
  border: 1px solid rgba(129, 140, 248, 0.55);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.9);
}

.freq-tag {
  font-size: 0.78rem;
  color: var(--accent-blue);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* =========================================================
   SPOTIFY EMBED
   ========================================================= */

.spotify-embed {
  margin-top: 1rem;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.9);
}

/* =========================================================
   AUDIO PLAYER RAÍZ SONORA
   ========================================================= */

.audio-player {
  margin-top: 1.5rem;
  background: radial-gradient(circle at top, rgba(56, 189, 248, 0.18), transparent),
              radial-gradient(circle at bottom, rgba(168, 85, 247, 0.22), #020617);
  border-radius: 1.2rem;
  padding: 1rem 1.25rem 1.1rem;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.25);
}

/* Contenedor principal del player */
.player-main {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.9rem;
}

/* Botones de control */
.btn-icon {
  background: linear-gradient(135deg, #22c55e, #14b8a6);
  border: none;
  color: #020617;
  font-size: 1.1rem;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 999px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 24px rgba(34, 197, 94, 0.55);
  transition: transform 0.12s ease, box-shadow 0.12s ease, opacity 0.12s ease;
}

.btn-icon:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 32px rgba(34, 197, 94, 0.72);
  opacity: 0.96;
}

.btn-icon:active {
  transform: translateY(0);
  box-shadow: 0 6px 14px rgba(34, 197, 94, 0.6);
}

/* Info de la pista */
.player-info {
  flex: 1;
}

.track-title {
  font-weight: 600;
  color: #e5e7eb;
  margin-bottom: 0.2rem;
}

.track-time {
  font-size: 0.78rem;
  color: #9ca3af;
  margin-bottom: 0.4rem;
}

/* Barra de progreso */
.progress-container {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.95);
  cursor: pointer;
  overflow: hidden;
  border: 1px solid rgba(37, 99, 235, 0.8);
}

.progress {
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #22c55e, #a855f7, #38bdf8);
  transition: width 0.15s linear;
}

/* Playlist */
.playlist {
  list-style: none;
  margin: 0.2rem 0 0;
  padding: 0.35rem 0 0;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
  max-height: 220px;
  overflow-y: auto;
}

/* Scroll fino */
.playlist::-webkit-scrollbar {
  width: 6px;
}
.playlist::-webkit-scrollbar-track {
  background: transparent;
}
.playlist::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.6);
  border-radius: 999px;
}

.track-item {
  padding: 0.55rem 0.15rem;
  font-size: 0.9rem;
  color: #d1d5db;
  cursor: pointer;
  border-bottom: 1px solid rgba(15, 23, 42, 0.7);
  transition: background 0.12s ease, color 0.12s ease, border-color 0.12s ease,
              transform 0.08s ease;
}

.track-item:last-child {
  border-bottom: none;
}

.track-item:hover {
  background: rgba(30, 64, 175, 0.45);
  color: #f9fafb;
  transform: translateX(2px);
}

/* Pista activa */
.active-track {
  color: #22c55e;
  border-color: rgba(34, 197, 94, 0.6);
  background: radial-gradient(circle at left, rgba(34, 197, 94, 0.12), transparent);
}

/* =========================================================
   FOOTER
   ========================================================= */

.main-footer {
  margin-top: 1.8rem;
  text-align: center;
  font-size: 0.8rem;
  color: #6b7280;
}

/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 800px) {
  .page {
    padding: 1rem 0.8rem 2.2rem;
  }

  .hero {
    padding: 1.8rem 1.2rem;
  }

  .freq-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 1.7rem;
  }

  .player-main {
    flex-direction: row;
    align-items: flex-start;
  }

  .btn-icon {
    width: 2.2rem;
    height: 2.2rem;
    font-size: 1rem;
  }

  .track-title {
    font-size: 0.95rem;
  }
}
/* =========================================================
   GRID PARA SESIONES (sessions-grid)
   ========================================================= */

.sessions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.2rem;
  margin-top: 1.2rem;
}

.session-card {
  background: radial-gradient(circle at top, rgba(56, 189, 248, 0.15), rgba(15,23,42,0.92));
  border-radius: 1.1rem;
  padding: 1.2rem 1.3rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: 0 18px 40px rgba(2,6,23,0.55);
  transition: transform .15s ease, box-shadow .15s ease;
}

.session-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 26px 55px rgba(2,6,23,0.7);
}

.session-card h3 {
  margin: 0 0 .4rem;
  font-size: 1.25rem;
  color: #e5e7eb;
}

.session-tag {
  font-size: .8rem;
  font-weight: 600;
  text-transform: uppercase;
  color: #38bdf8;
  letter-spacing: .08em;
  margin-bottom: .5rem;
}

.session-card p {
  margin: 0;
  color: #94a3b8;
}


/* =========================================================
   GRID PARA REFLEXIONES (reflection-grid)
   ========================================================= */

.reflection-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.3rem;
  margin-top: 1.3rem;
}

.reflection-card {
  background: radial-gradient(circle at bottom left, rgba(168,85,247,0.22), rgba(15,23,42,0.92));
  border-radius: 1.15rem;
  padding: 1.3rem 1.4rem;
  border: 1px solid rgba(148,163,184,.32);
  box-shadow: 0 20px 45px rgba(2,6,23,0.6);
  transition: transform .15s ease, box-shadow .15s ease;
}

.reflection-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 28px 60px rgba(2,6,23,0.8);
}

.reflection-card h3 {
  margin-top: 0;
  margin-bottom: .4rem;
  font-size: 1.2rem;
  color: #e2e8f0;
}

.reflection-text {
  color: #cbd5e1;
  font-size: .95rem;
  line-height: 1.55rem;
  margin: 0;
}
