/* ===== BASE ===== */
body {
  font-family: Arial, sans-serif;
  background-color: #0f172a;
  color: #e5e7eb;
  margin: 0;
}

.container {
  text-align: center;
  padding: 40px;
  padding-bottom: 80px;
  max-width: 800px;
  margin: auto;
}

h1 {
  margin-bottom: 10px;
}

/* ===== GRID HOME ===== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 20px;
  margin-top: 40px;
}

.card {
  background-color: #1e293b;
  padding: 20px;
  border-radius: 10px;
  text-decoration: none;
  color: white;
  transition: 0.2s;
  font-weight: bold;
}

.card:hover {
  background-color: #334155;
}

/* ===== SECCIONES ===== */
.section-title {
  margin-top: 50px;
  font-size: 20px;
  opacity: 0.8;
}

.grid-secondary {
  margin-top: 20px;
}

.card.secondary {
  background-color: #020617;
  border: 1px solid #334155;
}

.card.secondary:hover {
  background-color: #1e293b;
}

/* ===== BOTONES ===== */
.nav-buttons {
  margin-top: 30px;
}

.btn {
  display: inline-block;
  background-color: #1e293b;
  color: #e5e7eb;
  padding: 10px 18px;
  margin: 5px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: 0.2s;
  border: 1px solid #334155;
  box-shadow: 0 2px 5px rgba(0,0,0,0.3);
}

.btn:hover {
  background-color: #334155;
  transform: translateY(-2px);
}

/* ===== BLOQUE MORSE ===== */
.morse {
  font-family: monospace;
  font-size: 18px;
  background-color: #020617;
  padding: 15px;
  border-radius: 8px;
  display: inline-block;
  text-align: left;
  line-height: 1.8;
  letter-spacing: 2px;
  border: 1px solid #334155;
}

/* ===== AUDIO ===== */
.audio-block {
  margin-bottom: 30px;
  border-bottom: 1px solid #334155;
  padding-bottom: 20px;
}

.audio-row {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-top: 10px;
}

.audio-row audio {
  flex: 1;
}

.audio-row .btn {
  white-space: nowrap;
}

.audio-title {
  font-weight: bold;
  min-width: 100px;
  text-align: left;
  color: #38bdf8;
}

/* ===== LINKS ===== */
a {
  color: #38bdf8;
}

/* ===== LINK AUTOR ===== */
.author-link {
  color: #e5e7eb;
  text-decoration: none;
}

.author-link:hover {
  color: #38bdf8;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 600px) {
  .audio-row {
    flex-direction: column;
    align-items: stretch;
  }

  .audio-row .btn {
    width: 100%;
  }
}

.morse-grid {
  display: flex;
  justify-content: space-between;
  gap: 40px;
}

.morse-grid div {
  width: 100%;
}

/* ===== NAV FIJO ABAJO ===== */
.nav-buttons {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;

  background-color: #0f172a;
  border-top: 1px solid #334155;

  padding: 10px 0;
  text-align: center;
}