*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 100%; 
}

h1, p {
	margin:2rem;
}

h2, h3 {
    margin:1.5rem;
    text-align: center;
}

/*------LINKS-----------*/

a {
    text-decoration: none;
 }
a:visited {
    color: purple;
}

a:hover {
    color: red;
}

a:active {
    color: orange;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh; 
    min-height: 100dvh; /*dynamic viewport height - para móviles*/
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    line-height: 1.5;
    text-align: center;
}

main .ext-container {
	width: 80%;
	margin: 0 auto;
}

.hero {
    position: relative;
    width: 70%;
    min-height: 65vh;
    margin: 8rem auto 0;

    display: flex;
    align-items: center;
    justify-content: center;

    color: white;
    border-radius: 10px;
    box-shadow: 0 0 12px rgba(0, 0, 0, 0.5);

    overflow: hidden;
}

/* Imagen que sustituye al background-image */

.hero > picture {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.hero > picture > img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 55%;
}


/* Texto sobre la imagen */
.hero h1 {
    color: white;
    position: absolute;
    top: 60%;
    left: 50%;
    margin: 0;

    transform: translate(-50%, -50%);

    font-size: 2rem;
    text-shadow: 0 6px 4px rgba(0, 0, 0, 1);

    animation: fadein 4s;

    z-index: 1;
}


@keyframes fadein {
    0% {
        opacity:0;
    }
    50%{
        opacity:0.5;
    }
    100% {
        opacity:1;
    }
}


article h3 {
  color: #005B7F;
  font-style: italic;
  /*font-weight: bold;*/
}


.center {
  text-align: center;
  padding: 3rem 1rem;
  display: grid;
}

.callout {
  font-style: italic;
  font-size: 1.2rem;
  margin: 0 auto 2rem;
}

.button {
  min-width: 100px; /* asegura que no se haga demasiado pequeño */
  font-size: 1.2rem;
  padding: 0.7rem;
  border-radius: 6px;
  cursor: unset;
  margin: auto;
  background-color: #005B7F;
  color: white;
  font-weight:bold;
  transition:transform 0.3s ease
}


.button:hover {
	size;
	transform: scale(1.05);
}

.form-subscription {
    margin-top: 1rem;
    width: 35%;
    display: flex;
    flex-flow: column;
    align-items: center;
    border-radius: 8px;
    padding: 1rem;
    margin: 0 auto;
    background-color: #005B7F;
    color: #ffff;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.4);
}

label {
    display: block;
    margin-bottom: 0.4rem;
    color: #ffff;
    font-weight: bold; 
}

 input {
    width: 90%;
    margin: 0.5rem 0;
    border-radius: 8px;
    line-height:1.6rem;
    }
    
 input::placeholder {
 font-style: italic;
 }
    
 textarea label {
    margin:2rem 0;
    }
    
 textarea {
    width: 90%;
    margin: 0.5rem 0;
    border-radius: 8px;
    }

.submit-wrapper {
  display: flex;
  justify-content: center;
  margin-top: 1rem;
}

.form-subscription button {
  width: 25%;
  min-width: 120px; /* asegura que no se haga demasiado pequeño */
  font-size: 0.9rem;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  cursor: pointer;
  background-color: #FFFFFF;
  color: #003B5C;
  border: 2px solid #FFFFFF;
}

/*Mensajes éxito - error formulario*/

.form-message {
	margin-top: 1rem;
	opacity: 0;

	/* El mensaje aparece y desaparece suavemente */
	transition: opacity 1s ease;
}

/* Cuando el mensaje está activo, se muestra */
.form-message.success,
.form-message.error {
	opacity: 1;
}

/* Después de 5 segundos comienza el fade-out */
.form-message.fade-out {
	opacity: 0;
}

.form-message.success {
	color: green;
}

.form-message.error {
	color: red;
}



/*Estilos responsive*/


/*texto y botón callout*/

@media (max-width: 576px) {

	.hero h1 {
    font-size: 1.5rem;
  }

   .button {
    width: 80%; /* más espacio disponible */
    font-size: 1rem; /* ligeramente más pequeño */
    padding: 0.6rem 1.2rem; /* menos espacio interior */
  }
}

@media (max-width: 767px) {

.hero {
	margin-top:10rem;
	}
	
	.form-subscription{
	width:70%;
  }
}
