* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --color-texto: #504F4F;
    --color-fondo: #ebebeb;
    --color-hover: #272B26;
    --color-hover-menu: #b9b7b7;
}

html, body {
    background-color: var(--color-fondo);
    color: var(--color-texto);
    scroll-behavior: smooth;
}

body {
    display: grid;
    grid-template-rows: auto 1fr auto; 
    min-height: 100vh; 
}

.container {
    display: grid;
    grid-template-columns: 1fr; 
}

  /*** DISEÑO DEL HEADER ***/
header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 1rem;
    position: relative;
}

.header-space-I {
    flex: 0.5;
}

.header-space-II {
    flex: 0.35;
}

h1 {
    flex: 2;
    text-align: center;
    font-family: 'Special Elite', cursive;
    font-size: 2.5rem;
}

h1 a {
    text-decoration: none; 
    color: inherit;
}

h1 a:hover {
    cursor: pointer;
}

.header-button-mobile,
.nav-lang.mobile {
    display: none;
}

.header-button {
    flex: 0.1;
    text-decoration: none;
    text-align: center;
    color: var(--color-texto);
    padding: 0.5rem 1rem;
    margin-top: 5px;
    border: 1px solid var(--color-hover);
    border-radius: 5px;
    font-family: 'Questrial', sans-serif;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s ease-in-out, transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.header-button:hover {
    background-color: var(--color-hover);
    color: var(--color-fondo);
    transform: translateY(2px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/*** NAV BAR Y MENU ***/
.nav-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
}

.nav-menu {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 0;
    background-color: var(--color-texto);
    position: fixed;
    top: 0;
    left: 100%; 
    width: 100%; 
    height: 100%; 
    padding: 2rem 0;
    overflow-y: auto;
    transition: left 0.3s ease-in-out;
    z-index: 1000; 
}

.nav-menu li {
    margin: 1rem 0;
}

.nav-menu a {
    color: var(--color-fondo);
    text-decoration: none;
    font-family: 'Special Elite', cursive;
    font-size: 2rem;
    transition: color 0.3s ease-in-out;
}

.nav-menu a:hover {
    color: var(--color-hover-menu);
}

/* Botón del menú */
.menu-btn {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 3rem;
    height: 3rem;
    cursor: pointer;
    z-index: 1100;
    position: fixed;
    top: 1rem;
    right: 2.5rem;
}

.menu-btn_burguer {
    width: 2rem;
    height: 0.2rem;
    background: var(--color-texto);
    border-radius: 0.5rem;
    position: relative;
    transition: all 0.3s ease-in-out;
}

.menu-btn_burguer::before,
.menu-btn_burguer::after {
    content: '';
    position: absolute;
    width: 2rem;
    height: 0.2rem;
    background: var(--color-texto);
    border-radius: 0.5rem;
    transition: all 0.3s ease-in-out;
}

.menu-btn_burguer::before {
    transform: translateY(-0.5rem);
}

.menu-btn_burguer::after {
    transform: translateY(0.5rem);
}

.menu-btn:hover .menu-btn_burguer {
    background: var(--color-hover); 
}

.menu-btn:hover .menu-btn_burguer::before,
.menu-btn:hover .menu-btn_burguer::after {
    background: var(--color-hover);
}

/* Resultado final del menú */
.menu-btn.open .menu-btn_burguer {
    background: transparent;
}

.menu-btn.open .menu-btn_burguer::before {
    transform: rotate(45deg);
    background: var(--color-fondo);
}

.menu-btn.open .menu-btn_burguer::after {
    transform: rotate(-45deg);
    background: var(--color-fondo);
}

.menu-btn.open:hover .menu-btn_burguer::before {
    background: var(--color-hover-menu);
}

.menu-btn.open:hover .menu-btn_burguer::after {
    background: var(--color-hover-menu);
}

.nav-menu_visible {
    left: 0;
}

  /*** DISEÑO DEL MAIN ***/
main {
    margin-bottom: 3rem;
}

  /* Botón de audio */
.sound-toggle-container {
    display: flex;
    justify-content: center;
    max-width: 1100px;
    margin: 20px auto;
}

.sound-toggle {
    display: flex;
    align-items: center;
    gap: 15px;
    border: none;
    padding: 0 20px 10px;
    cursor: pointer;
    border-radius: 10px;
    font-family: 'Covered By Your Grace', cursive;
    color: var(--color-texto);
    font-size: 1.6rem;
    transition: color 0.3s ease, filter 0.3s ease;
}

.sound-toggle:hover {
    color: var(--color-hover);
}

.sound-icon {
    width: 26px;
    height: auto;
    transition: filter 0.3s ease;
}

.sound-toggle:hover .sound-icon {
    filter: brightness(0.7);
}

    /* Diseño de imágenes*/
.image-container {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 1100px;
    margin: 1rem auto; 
}

.image-container img {
    max-width: 45%;
    position: relative; 
}

.maquina-escribir {
    transition: opacity 0.5s ease;
    right: 13px;
}

#maquina-ingles {
    position: relative;
    right: 20px;
}

.maquina-escribir:hover {
    opacity: 0.6;
}

  /* Flechas y texto */
.manuscrito {
    font-family: 'Covered By Your Grace', cursive;
    color: var(--color-texto);
    font-size: 1.6rem;
    transition: color 0.3s ease;
}

.manuscrito:hover {
    color: var(--color-hover);
}

#manuscrito-izquierda-primero {
    transform: translateX(-6%) translateY(-6%) rotate(-45deg);
}

#manuscrito-izquierda-primero-ingles {
    transform: translateX(11%) translateY(-6%) rotate(-45deg);
}

#manuscrito-derecha-primero {
    transform: translateX(11%) translateY(-6%) rotate(45deg);
}

#manuscrito-derecha-primero-ingles {
    transform: translateX(-8%) translateY(-12%) rotate(45deg);
}

#manuscrito-izquierda-segundo {
    transform: translateX(55%) translateY(28%) rotate(45deg);
}

#manuscrito-derecha-segundo {
    transform: translateX(-40%) translateY(-12%) rotate(-48deg);
}

.flecha {
    width: 1.4rem;
    transition: transform 0.3s ease;
}

#flecha-izquierda-primero {
    transform: translateX(-420%) translateY(-51%) rotate(157deg);
}

#flecha-izquierda-primero-ingles {
    transform: translateX(-288%) translateY(-51%) rotate(157deg);
}

#flecha-derecha-primero {
    transform: translateX(-420%) translateY(-56%) rotate(-157deg);
}

#flecha-derecha-primero-ingles {
    transform: translateX(-288%) translateY(-56%) rotate(-157deg);
}

#flecha-derecha-segundo {
    transform: translateX(-300%) translateY(127%) rotate(19deg);
}

#flecha-izquierda-segundo {
    transform: translateX(-256%) translateY(126%) rotate(-19deg);
}

  /* enlaces de los textos */
.enlaces-main {
    position: relative; 
    display: inline-block; 
    text-decoration: none;  
}

.enlaces-main > span {
    display: inline-block; 
    white-space: nowrap;
}

/* Diseño de video */
.video-container {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 1100px;
    margin: 3rem auto;
}

.video-container iframe {
    width: 70%;
    max-width: 800px; 
    height: auto; 
    aspect-ratio: 16 / 9;
    border-radius: 1rem; 
    overflow: hidden;
}

/* Sección Sobre Fragmentos y Sobre nosotros */
.acerca-de-container {
    position: relative;
    background-color: #f5f5f5;
    display: flex;
    justify-content: center;
}

.acerca-de {
    padding: 2rem;
    max-width: 1100px;
    width: 90%;
    box-sizing: border-box;
}

.textos {
    max-width: 75%;
    margin: 20px auto;
    text-align: left;
    font-family: 'Questrial', sans-serif;
    font-size: 1.3rem;
    line-height: 1.35;
    color: var(--color-texto);
}

/* Galería de imágenes */
.galeria {
    columns: 4 240px;
    column-gap: 1em;
    padding: 10px;
    max-width: 1100px;
    margin: 3rem auto;
}

.galeria a {
    display: block;
    transition: transform 0.3s ease-in-out;
    margin-bottom: 1em;
}

.galeria a:hover {
    transform: scale(1.05);
}

.galeria img {
    width: 100%;
    display: block;
    border-radius: 10px;
}

/* Redes sociales y newsletter */
.social-media-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    padding: 3rem 3rem 2rem;
}

h2 {
    text-align: center;
    font-family: 'Special Elite', cursive;
    font-size: 2.5rem;
    margin: 1rem auto;
}

.texto-formulario {
        text-align: center;
        font-family: 'Questrial', sans-serif;
        font-size: 1.3rem;
        color: var(--color-texto);
        margin: 0.5rem auto;
}

.social-media a {
    color: var(--color-texto);
    font-size: 2rem;
    text-decoration: none;
    transition: color 0.3s ease, filter 0.3s ease;
}

.social-media a:hover {
    color: var(--color-hover);
    filter: brightness(0.7);
}

/** CONTENEDOR DEL FORMULARIO **/
.subscribe-container {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 1100px;
    margin: 0 auto; 
}

#mc_embed_signup {
    padding: 20px;
}

.mc-field-group {
    margin: 0 0 15px;
}

.mc-field-group label {
    display: block;
    margin: 0 3px 5px;
    font-family: 'Lato', sans-serif;
    font-style: italic;
    font-size: 1rem;
    color: var(--color-texto);
}

.mc-field-group input.email {
    width: 300px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: 'Lato', sans-serif;
    font-size: 14px;
    color: var(--color-texto);
}

.clear.foot {
    display: flex;
    justify-content: center;
    align-items: center;
}

.button {
    border: 1px solid var(--color-texto);
    color: var(--color-texto);
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    margin: 4px 2px;
    cursor: pointer;
    border-radius: 5px;
    transition: background 0.3s ease-in-out;
}

.button:hover {
    background-color: var(--color-hover);
    color: var(--color-fondo);
}

#mce-responses .response {
    display: none;
    margin: 10px 0;
}

.refferal_badge {
    display: block;
}

.hidden {
    display: none;
}

  /*** DISEÑO DEL FOOTER ***/
footer {
    border-top: 1px solid var(--color-texto);
}

.footer-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    padding: 1rem;
    max-width: 1100px;
    margin: 0 auto;
}

.footer-left {
    text-align: left;
}

.footer-left a {
    text-decoration: none;
}

.footer-left a:hover {
    color: var(--color-hover);
}

.footer-right {
    text-align: right;
}

.texto-footer {
    text-align: center;
    font-family: 'Questrial', sans-serif;
    font-size: 1.1rem;
    color: var(--color-texto);
    margin: 0.5rem auto;
}