@media only screen and (max-width: 300px) {
    ul, ol {
        padding-left: 12px; /* Ligeramente mayor para dar un poco más de aire */
    }

    ul li, ol li {
        font-size: 0.95em; /* Tamaño base en pantallas pequeñas */
        padding-left: 8px; /* Incrementé para mejor separación visual */
        margin-bottom: 8px; /* Ajusté para consistencia */
        line-height: 1.5; /* Aumenté ligeramente para más claridad */
    }

    /* Reducción para listas numeradas anidadas en pantallas pequeñas */
    ol ol li, .lista-hitos-interna li {
        font-size: 0.9em; /* Nivel 2 */
    }

    ol ol ol li, ol ol .lista-hitos-interna li {
        font-size: 0.85em; /* Nivel 3 o más profundo */
    }

    .lista-viñetas-secundaria, .lista-hitos-interna, .lista-viñetas-terciaria {
        padding-left: 10px; /* Incrementé para diferenciar niveles más profundos */
    }
}

body {
    background-color: #f4f1e3;
    font-family: 'Times New Roman', Times, serif;
}

.titulo-principal {
    color: #704214;
    text-align: center;
    margin-top: 20px;
    font-size: 2.5em;
    text-shadow: 1px 1px 2px #000000;
}

.subtitulo {
    color: #8b4513;
    text-align: center;
    margin-bottom: 20px;
    font-size: 1.8em;
}

.contenedor {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    background-color: #fafafa;
    border: 5px double #e0d8c3;
    border-radius: 15px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    padding: 30px;
    transition: box-shadow 0.3s ease, border 0.3s ease;
}

.contenedor:hover {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    border: 5px double #c0b090;
}

.contenido-modulos {
    background-color: #fff5e6;
    border: 1px solid #deb887;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.contenido-modulos:hover {
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
    border-color: #8b4513;
}

.contenido {
    background-color: #faf7f0;
    border: 1px solid #d1c4a9;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
    background-image: linear-gradient(to bottom, #ffffff, #faf7f0);
    transition: all 0.3s ease;
}

.contenido:hover {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    border-color: #b0a280;
    transform: translateY(-3px);
}

.contenido h2 {
    color: #704214;
    font-size: 1.8em;
    margin-bottom: 15px;
    text-shadow: 1px 1px 2px #000000;
}

.contenido p {
    color: #5f370e;
    font-size: 1.1em;
    line-height: 1.6;
    margin-bottom: 20px;
}

.parrafo-leyenda {
    font-style: italic;
    color: #704214;
    border-left: 4px solid #8b4513;
    padding-left: 15px;
    margin: 20px 0;
    background-color: #f9f2ec;
    border-radius: 8px;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
    font-size: 1.2em;
}

.parrafo-listas {
    color: #5f370e;
    font-size: 1.1em;
    font-weight: bold;
    margin-bottom: 10px;
}

.parrafo-referencia-superior {
    font-style: italic;
    color: #704214;
    border-left: 4px solid #8b4513;
    padding-left: 15px;
    margin-bottom: 20px;
    background-color: #f9f2ec;
    border-radius: 8px;
    font-size: 1.2em;
}

.subtitulo-interno, .sub-subtitulo {
    color: #704214;
    font-size: 1.5em;
    margin-bottom: 10px;
    text-shadow: 1px 1px 2px #000000;
}

a {
    color: #8b4513;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
    color: #704214;
}

footer {
    background-color: #f4f1e3;
    text-align: center;
    padding: 10px 0;
    margin-top: 20px;
    border-top: 2px solid #deb887;
}

.lista-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: center;
}

.lista-menu li {
    display: inline;
    margin: 0 10px;
}

.boton {
    background-color: #8b4513;
    color: #ffffff;
    padding: 10px 20px;
    border-radius: 5px;
    text-shadow: 1px 1px 2px #000000;
    text-decoration: none;
}

.boton:hover {
    background-color: #704214;
}

/* Estilo de listas */
.lista-numerada {
    list-style-type: decimal;
    margin-left: 3px;
    margin-bottom: 20px;
    line-height: 1.6;
    font-size: 1.2em; /* Tamaño base */
    color: #5f370e;
}

/* Listas numeradas anidadas (nivel 2) */
ol .lista-numerada, ol .lista-hitos-interna {
    font-size: 1.1em; /* Reducido un poco */
}

/* Listas numeradas anidadas (nivel 3 o más profundo) */
ol ol .lista-numerada, ol ol .lista-hitos-interna {
    font-size: 1.0em; /* Más pequeño */
}

.lista-viñetas {
    list-style-type: circle;
    margin-left: 5px;
    margin-bottom: 15px;
    line-height: 1.5;
    font-size: 1em;
    color: #704214;
}

.lista-viñetas-secundaria {
    list-style-type: disc;
    margin-left: 7px;
    margin-bottom: 15px;
    line-height: 1.4;
    font-size: 1.0em;
    color: #704214;
}

.lista-viñetas-terciaria {
    list-style-type: square;
    margin-left: 0px;
    margin-bottom: 15px;
    line-height: 1.3;
    font-size: 0.9em;
    color: #704214;
}

.lista-hitos {
    list-style-type: circle;
    margin-left: 10px;
    margin-bottom: 15px;
    line-height: 1.5;
    font-size: 1.1em;
    color: #704214;
}

.lista-hitos-interna {
    list-style-type: decimal;
    margin-left: 20px;
    margin-bottom: 15px;
    line-height: 1.4;
    font-size: 1em; /* Tamaño base, se reducirá si está anidada */
    color: #704214;
}

.dl {
    margin-bottom: 20px;
    font-size: 1.15em;
    line-height: 1.6;
}

dt {
    font-weight: bold;
    color: #704214;
    margin-top: 10px;
    margin-bottom: 5px;
    font-size: 1.2em;
}

dd {
    margin-left: 5px;
    margin-bottom: 5px;
    font-size: 1.1em;
    color: #8b4513;
    line-height: 1.6;
}

/* Botones de navegación */
nav ul.lista-menu {
    text-align: center;
    margin-top: 20px;
}

nav .boton-historia.nav-izquierda {
    float: left;
    margin-left: 20px;
}

nav .boton-historia.nav-derecha {
    float: right;
    margin-right: 20px;
}

/* Clearfix para flotantes */
.contenedor::after, footer::after {
    content: "";
    display: table;
    clear: both;
}

/* Imagen */
.contenedor-imagen {
    display: flex;
    flex-direction: column;
    text-align: center;
    margin: 0;
    padding: 0;
}

.contenido-imagen {
    width: 100%;
    height: auto;
    margin: 0;
    padding: 0;
}

.contenido-imagen-dos {
    width: 100%;
    height: auto;
    padding-bottom: 1em;
}

img {
    max-width: 100%;
    max-height: 100vh;
    width: auto;
    height: auto;
    margin: 0;
    padding: 0;
}
/* Fin Imagen */