.imagen-header {
  width: 100%;
  max-width: 600px;
  height: auto;
  opacity: 0;
  transform: scale(0.95) translateY(-30px);
  transition: opacity 1.5s ease, transform 1.5s ease;
  border-radius: 20px;
  animation: pulsoEstelar 4s ease-in-out infinite;
}

body {
  font-family: 'Arial', sans-serif;
  margin: 0;
  padding: 0;
  background-color: #7f5797;
  color: #383643;
  text-align: center;
  cursor: url('img/varita.png') 0 0, auto;
}

body.loaded .imagen-header {
  opacity: 1;
  transform: scale(1);
}

@keyframes pulsoEstelar {
  0%, 100% { filter: brightness(1); }
  50% { filter: brightness(1.1); }
}

header {
  text-align: center;
  background-color: #7f5797;
  padding: 40px 20px;
  border-bottom: 2px solid #c4dcf7;
}

header h1,
header p {
  color: white;
  text-align: center;
}

header h1 {
  font-size: 2.5em;
}

header p {
  font-size: 1.3rem;
  font-weight: 400;
}

nav {
  display: flex;
  justify-content: center;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 20px;
  padding: 0;
}

nav ul li a {
  text-decoration: none;
  color: #fff;
  font-size: 1.2em;
  padding: 10px 20px;
  background-color: #99a4bc;
  border-radius: 5px;
  font-weight: 600;
  transition: background-color 0.3s ease;
}

nav ul li a:hover {
  color: #5e148c;
}

.bienvenida {
  position: relative;
  padding: 50px 20px;
  margin: 50px auto;
  width: 80%;
  max-width: 800px;
  text-align: center;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(6px);
  border-radius: 20px;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
  animation: fadeInUp 2s ease forwards;
  opacity: 0;
}

.bienvenida h2 {
  font-size: 2.5rem;
  color: #ffd700;
  margin-bottom: 10px;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.bienvenida p {
  font-size: 1.8rem;
  color: #ffffff;
  line-height: 1.6;
  margin-top: 15px;
  text-shadow: 0 0 5px rgba(255, 255, 255, 0.1);
}

@keyframes fadeInUp {
  0% {
    opacity: 0;
    transform: translateY(30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.contenido {
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 40px;
  flex-wrap: wrap;
}

.tarjeta {
  background-color: #ecd2ff;
  padding: 20px;
  width: 300px;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.tarjeta h3 {
  color: #7f5797;
}

.tarjeta-azul {
  background-color: #dbe7f0;
  border-left: 5px solid #74c0fc;
}

.tarjeta-verde {
  background-color: #e0f7e3;
  border-left: 5px solid #69db7c;
}

.tarjeta-dorada {
  background-color: #fff3bf;
  border-left: 5px solid #ffcc00;
}

.submit, .boton-enviar {
  background: linear-gradient(135deg, #7b1ab3, #ac79d4);
  color: white;
  font-size: 1.2em;
  padding: 12px 24px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  margin-top: 20px;
  display: inline-block;
  text-transform: uppercase;
  font-weight: bold;
  width: auto;
  box-shadow: 0px 6px 12px rgba(183, 192, 231, 0.2);
}

.submit {
  transform: scale(1.05);
}

.boton-enviar:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

#contact {
  padding: 40px;
  background-color: rgb(229, 204, 236);
  border-radius: 8px;
  width: 100%;
  margin: 0 auto;
  max-width: 600px;
}

#contact h2 {
  text-align: center;
  margin-bottom: 20px;
}

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

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 10px;
  font-size: 1em;
  border: 1px solid #ddd;
  border-radius: 10px;
}

.form-group textarea {
  resize: vertical;
}

footer {
  background-color: #7f5797;
  color: rgb(170, 90, 216);
  padding: 20px;
  text-align: center;
}

.social-icons a {
  color: #c2b6d3;
  font-size: 32px;
  margin: 0 15px;
  transition: color 0.3s ease;
}

.social-icons a:hover {
  color: white;
}

/* Estrellas dinámicas */

.star {
  position: fixed;
  width: 7px;
  height: 7px;
  background-color: white;
  border-radius: 50%;
  pointer-events: none;
  animation: desaparecer 0.3s ease-out forwards;
}

@keyframes desaparecer {
  0% {
    opacity: 1;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(0);
  }
}

.estrellas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

@keyframes parpadeo {
  0%, 100% { opacity: 0.2; }
  50% { opacity: 1; }
}

@keyframes flotar {
  0% {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
  100% {
    transform: translateY(-100vh) scale(0.5);
    opacity: 0;
  }
}

.spark {
  position: absolute;
  width: 10px;
  height: 10px;
  background: radial-gradient(circle, #fff9c4 0%, #fbc02d 70%, transparent 80%);
  border-radius: 50%;
  pointer-events: none;
  animation: sparkAnim 0.6s forwards;
  filter: drop-shadow(0 0 6px #fbc02d);
}

@keyframes sparkAnim {
  0% {
    opacity: 1;
    transform: scale(1) translate(0, 0);
  }
  100% {
    opacity: 0;
    transform: scale(2) translate(20px, -20px);
  }
}

#maquina-titulo {
  font-size: 2.5rem;
  font-weight: bold;
  text-align: center;
  color: #f8ba3f;
  margin-top: 40px;
}

#maquina-parrafo {
  font-size: 1.25rem;
  max-width: 800px;
  margin: 20px auto;
  text-align: justify;
  color: #f8f8f8;
  line-height: 1.6;
}

.tarjeta-azul,
.tarjeta-verde,
.tarjeta-dorada {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
  border-radius: 8px;
  position: relative;
  z-index: 0;
}

.tarjeta-azul:hover {
  transform: scale(1.05) translateY(-10px);
  box-shadow:
    0 10px 20px rgba(0, 0, 139, 0.4),
    0 0 15px 3px rgba(0, 0, 139, 0.7);
  z-index: 10;
}

.tarjeta-verde:hover {
  transform: scale(1.05) translateY(-10px);
  box-shadow:
    0 10px 20px rgba(0, 128, 0, 0.4),
    0 0 15px 3px rgba(0, 128, 0, 0.7);
  z-index: 10;
}

.tarjeta-dorada:hover {
  transform: scale(1.05) translateY(-10px);
  box-shadow:
    0 10px 20px rgba(218, 165, 32, 0.4),
    0 0 15px 3px rgba(218, 165, 32, 0.7);
  z-index: 10;
}
