/* Estilos generales para las secciones */
.container {
    max-width: 1200px; /* Ancho máximo para el contenido en escritorio */
    margin: 0 auto;    /* Centra el contenedor horizontalmente */
    padding: 20px;     /* Espaciado interno general */
}

/*Inicio*/

/* Estilos específicos para la sección Home */
#home {
    padding-bottom: 40px; /* Mantener el padding inferior */
    text-align: left; /* El título y contenido se alinean a la izquierda */
}

.home-content h1 {
    font-size: 3em; /* Tamaño de fuente para el título "Bienvenidos" */
    color: #333;    /* Color del título */
    margin-bottom: 30px; /* Espacio debajo del título */
    font-weight: 900; /* Especificar Lato Black para escritorio */
}

/* Estilo para el bloque gris de ancho completo en escritorio y móvil */
.grey-block {
    background-color: #f2f2f2; /* Fondo gris */
    padding: 20px 0; /* Padding vertical, el horizontal lo manejará el .container interno */
    margin-bottom: 30px;
    box-shadow: inset 0px 2px 5px rgba(0,0,0,0.2); /* Inner shadow */
    width: 100vw; /* Usar viewport width para que ocupe todo el ancho */
    box-sizing: border-box; /* Incluye padding y borde en el ancho total */
    margin-left: calc(-50vw + 50%); /* Truco para extenderse a los bordes */
    margin-right: calc(-50vw + 50%); /* Truco para extenderse a los bordes */
}

/* Aseguramos que el párrafo dentro del .grey-block no tenga márgenes extras */
.grey-block p {
    margin: 0;
    line-height: 1.6; /* Espaciado entre líneas para mejor lectura */
    color: #555;
    text-align: left; /* Alineación del texto dentro del bloque */
    padding: 15px;
    font-size: 1.1em;
}

/* Ajuste para el contenedor interno del bloque gris */
.grey-block .container {
    max-width: 1200px; /* Mantener el max-width para escritorio */
    margin: 0 auto;
    padding: 0 20px; /* Aquí controlamos el padding horizontal del contenido interno */
}

.highlight-text {
    /* Este bloque no tiene fondo, es texto directo sobre la página */
    padding: 0; /* El padding horizontal ya lo dará el .container padre */
    margin-bottom: 20px;
    text-align: left;
    line-height: 1.6;
    color: #333;
    font-size: 1.1em;
}

.highlight-text p {
    font-weight: bold; /* El párrafo principal dentro de este bloque es negrita */
    margin-bottom: 10px; /* Espacio debajo del párrafo principal */
}

.highlight-text ul {
    list-style-type: disc; /* Estilo de viñeta para la lista */
    margin-left: 40px; /* Indentación de la lista */
    padding: 0;
}

.highlight-text ul li {
    margin-bottom: 5px; /* Espacio entre elementos de la lista */
}

/* --- Media Queries para responsividad (versión móvil) --- */
@media (max-width: 768px) {
    .container {
        padding: 15px; /* Reducir el padding en móviles */
    }

    #home {
        padding-bottom: 30px; /* Reducir el padding inferior en móviles */
    }

    .home-content h1 {
        font-size: 2em; /* Reducir el tamaño del título en móviles */
        margin-bottom: 20px;
        font-weight: bold; /* Usar bold en lugar de black para mejor compatibilidad en móvil */
        text-align: center;
    }

    /* El .grey-block sigue extendiéndose de borde a borde en móvil */
    .grey-block {
        padding: 15px 15px; /* Ajuste el padding vertical para móviles, el horizontal lo maneja el .container interno */
        margin-bottom: 20px;
        /* Las propiedades width, margin-left, margin-right ya están definidas arriba y se mantienen */
        font-size: 1em;
    }

    /* Ajustamos el padding horizontal del .container DENTRO del .grey-block para alinear su contenido */
    .grey-block .container {
        padding: 0 15px; /* Asegura el padding lateral del contenido interno del bloque gris en móviles */
    }
    
    .highlight-text {
        padding: 0; /* Se mantiene sin padding propio, lo gestiona el .container padre */
        margin-bottom: 20px;
    }

    .highlight-text ul {
        margin-left: 30px; /* Ajuste la indentación de la lista en móviles */
    }
}

@media (max-width: 480px) {
    .home-content h1 {
        font-size: 2em; /* Ajuste adicional para pantallas muy pequeñas */
    }
}

/* --- Sección de Curriculum Vitae (CV) --- */

#cv {
    padding-bottom: 40px;
}

/* Título principal de la sección (ej. "Curriculum Vitae") */
#cv h1 {
    font-size: 3em;
    color: #333;
    margin-bottom: 30px;
    font-weight: 900; /* Lato Black */
    text-align: left;
}

#cv h2, #cv h3, #cv h4, #cv p {
    color: #333;
    font-weight: 400; /* Por defecto Lato Regular */
}

/* Material Symbols - Estilo base (ahora a 25px por defecto) */
.material-symbols-outlined {
    font-variation-settings:
    'FILL' 0,
    'wght' 400,
    'GRAD' 0,
    'opsz' 25; /* Tamaño óptico ajustado a 25px */
    font-size: 25px; /* Tamaño del icono ajustado a 25px */
    vertical-align: middle;
    line-height: 1;
    display: inline-block;
    color: inherit;
}

/* Iconos de flecha roja para títulos de sección (Habilidades, Experiencia, Formación) */
.icon-red {
    color: #ff0000; /* Rojo vibrante */
    margin-right: 8px;
    font-weight: 700;
    font-variation-settings: 'FILL' 1, 'wght' 700, 'opsz' 25; /* Relleno, bold, tamaño 25px */
}

/* Contenedores de columnas para PC (Flexbox) */
.cv-content-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    align-items: flex-start;
}

.cv-left-column {
    flex: 0 0 250px;
}

.cv-right-column {
    flex: 1;
    min-width: 0;
}

/* Ocultar sección de perfil móvil en PC */
.profile-section-mobile {
    display: none;
}

/* Perfil (Desktop) */
.profile-section-desktop {
    text-align: center;
}

.profile-pic {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 20px;
    background-color: #e0e0e0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.profile-pic img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Nombre Apellido */
.profile-section h2 {
    font-size: 1.6em;
    margin-top: 15px;
    margin-bottom: 5px;
    font-weight: 700; /* Lato Bold */
}

.profile-section .occupation {
    font-size: 1.1em;
    margin-bottom: 30px;
    color: #666;
}

/* Habilidades */
.skills-section {
    order: 2;
}

.skills-section h3 {
    text-align: left;
    font-size: 1.4em;
    margin-top: 40px;
    margin-bottom: 20px;
    font-weight: 700; /* Lato Bold */
    display: flex;
    align-items: center;
}

.skills-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-start;
}

.skill-btn {
    background-color: #ff0000;
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9em;
    font-weight: bold;
    text-transform: uppercase;
}

/* Contenido Principal (Experiencia y Formación) */
.cv-right-column h3 {
    font-size: 1.4em;
    margin-bottom: 20px;
    font-weight: 700; /* Lato Bold */
    display: flex;
    align-items: center;
}

.cv-right-column h4 { /* Títulos de Cargo/Grado */
    font-size: 1.2em;
    margin-bottom: 5px;
    font-weight: 700; /* Lato Bold */
    font-variant: bold;
}

.cv-right-column .year,
.cv-right-column .institution {
    font-size: 1em;
    color: #777;
    margin-bottom: 10px;
}

.cv-right-column p {
    font-size: 1.1em;
    line-height: 1.6;
    color: #555;
    margin-bottom: 0;
    margin-bottom: 40px;
}

/* Línea de tiempo - Eliminar la línea vertical */
.timeline {
    position: relative;
    padding-left: 0; /* Ya no necesitamos padding para la línea */
    margin-left: 0;
}

.timeline::before {
    display: none; /* OCULTAR LA LÍNEA VERTICAL */
}

.timeline-item {
    position: relative;
    margin-bottom: 30px;
    padding-left: 35px; /* Espacio para el icono, ligeramente más que antes */
}

/* Estilos para el contenedor del ícono en la línea de tiempo (ya no necesita cortar línea) */
.timeline-icon {
    position: absolute;
    left: 0;
    top: 0;
    font-size: 25px; /* Tamaño de 25px para los iconos de la línea de tiempo */
    color: #ff0000; /* Color rojo del icono */
    transform: none; /* Ya no necesitamos transformar si no hay línea que centrar en ella */
    background-color: transparent; /* Fondo transparente */
    padding: 0; /* Sin padding */
    line-height: 1;
    z-index: auto; /* Z-index por defecto */
}

/* Ajustes específicos para los íconos Material Symbols */
/* Icono 'nearby' (Experiencia laboral) */
.timeline-icon.material-symbols-outlined:contains("nearby") {
    font-variation-settings: 'FILL' 0, 'wght' 400; /* NO relleno, peso regular */
    border: 1px solid #ff0000; /* Borde rojo */
    border-radius: 0; /* Cuadrado */
    padding: 2px; /* Ajusta el padding para el borde */
    /* Asegurar que el icono 'nearby' mantenga su forma */
}

/* Icono 'check_circle' (Formación) */
.timeline-icon.material-symbols-outlined:contains("check_circle") {
    font-variation-settings: 'FILL' 1, 'wght' 700; /* Relleno y bold */
    background-color: #ff0000; /* Fondo rojo para el círculo */
    color: #fff; /* Color blanco del check */
    border-radius: 50%; /* Hacer el fondo circular */
    padding: 2px; /* Ajusta el padding para el borde */
}

.timeline-item:last-child {
    margin-bottom: 0;
}
.education-section{
    margin-top: 40px;
}


/* --- Media Queries para responsividad (versión móvil) --- */
@media (max-width: 768px) {
    #cv h1 {
        font-size: 1.8em;
        margin-bottom: 20px;
        text-align: center;
    }

    .profile-section-desktop {
        display: none;
    }

    .profile-section-mobile {
        display: block;
        text-align: center;
        margin-bottom: 30px;
        order: -1;
    }

    .profile-section-mobile .profile-section h2,
    .profile-section-mobile .profile-section .occupation {
        text-align: center;
    }

    .cv-content-wrapper {
        flex-direction: column;
        gap: 20px;
    }

    .cv-left-column,
    .cv-right-column {
        flex: auto;
        width: 100%;
    }

    .cv-left-column {
        order: 2;
    }

    .cv-right-column {
        order: 1;
    }

    .skills-section {
        order: 2;
    }

    .experience-section {
        order: 0;
    }

    .education-section {
        order: 1;
        margin-top: 40px;
    }

    .skills-section h3,
    .cv-right-column h3 {
        justify-content: center;
        text-align: center;
        margin-top: 20px;
        margin-bottom: 15px;
        font-size: 1.2em;
        font-weight: 700;
    }

    .skills-buttons {
        justify-content: center;
        gap: 8px;
        margin-bottom: 30px;
    }

    .skill-btn {
        padding: 8px 15px;
        font-size: 0.85em;
    }

    /* Línea de tiempo en móvil (sin línea vertical) */
    .timeline {
        padding-left: 0;
        margin-left: 0;
        text-align: left;
    }

    .timeline::before {
        display: none; /* OCULTAR LA LÍNEA VERTICAL TAMBIÉN EN MÓVIL */
    }

    .timeline-item {
        padding-left: 35px; /* Espacio para el icono al inicio del ítem */
        margin-bottom: 20px;
        text-align: left;
    }

    .timeline-icon {
        left: 0; /* El icono está al borde del padding-left del item */
        transform: none; /* No hay línea que centrar */
        font-size: 25px; /* Asegurar 25px en móvil */
    }

    /* Estilos específicos para los iconos en móvil */
    /* Icono 'nearby' (Experiencia laboral) en móvil */
    .timeline-icon.material-symbols-outlined:contains("nearby") {
        font-variation-settings: 'FILL' 0, 'wght' 400; /* No relleno, regular */
        border: 1px solid #ff0000; /* Borde rojo */
        background-color: transparent; /* Transparente */
        padding: 2px;
        border-radius: 0;
    }

    /* Icono 'check_circle' (Formación) en móvil */
    .timeline-icon.material-symbols-outlined:contains("check_circle") {
        font-variation-settings: 'FILL' 1, 'wght' 700; /* Relleno, bold */
        background-color: #ff0000; /* Fondo rojo */
        color: #fff; /* Blanco */
        border-radius: 50%;
        padding: 2px;
    }

    /* Aumento de tamaño de texto de contenido para legibilidad en móvil */
    .timeline-content h4 {
        font-size: 1.2em;
    }

    .timeline-content .year,
    .timeline-content .institution {
        font-size: 1.1em; /* Aumentado nuevamente para mejor legibilidad */
        line-height: 1.4;
    }

    .timeline-content p {
        font-size: 1.2em; /* Aumentado nuevamente para mejor legibilidad */
        line-height: 1.7;
    }
}

@media (max-width: 480px) {
    #cv h1 {
        font-size: 1.8em;
    }
    .profile-pic {
        width: 130px;
        height: 130px;
    }

    .profile-section h2 {
        font-size: 1.5em;
    }

    .occupation {
        font-size: 0.9em;
    }

    .skills-buttons {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
        justify-content: center;
        gap: 6px;
    }

    .skill-btn {
        width: 100%;
        box-sizing: border-box;
        padding: 7px 12px;
        font-size: 0.8em;
    }

    .timeline-item {
        padding-left: 30px;
    }

    .timeline-icon {
        font-size: 22px; /* Ligeramente más pequeño en los dispositivos más pequeños */
    }

    .timeline-content h4 {
        font-size: 1.1em;
    }
    .timeline-content .year,
    .timeline-content .institution {
        font-size: 1.05em;
    }
    .timeline-content p {
        font-size: 1.1em;
    }
}

/* --- Sección de Contacto --- */
#contacto {
    padding-bottom: 60px;
    background-color: #fff;
}

#contacto h1 {
    font-size: 3em;
    color: #333;
    margin-bottom: 30px;
    font-weight: 900; /* Lato Black */
    text-align: left;
}

#contacto .subtitle {
    font-size: 1.2em;
    color: #555;
    margin-bottom: 25px;
    text-align: left;
}

/* Estilos del formulario */
.contact-form {
    margin-bottom: 40px;
}

.contact-form .form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.contact-form .form-group {
    flex: 1;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    font-size: 1em;
    font-family: 'Lato', sans-serif;
    color: #333;
    box-sizing: border-box;
    background-color: #f8f8f8;
}

.contact-form textarea {
    resize: vertical;
    margin-bottom: 20px;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: #a0a0a0;
}

.security-fields {
    font-size: 0.9em;
    color: #888;
    margin-bottom: 20px;
}

.send-btn {
    background-color: #ff0000;
    color: #fff;
    border: none;
    padding: 12px 30px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.1em;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.send-btn:hover {
    background-color: #cc0000;
}

/* Sección de Ubicación */
.location-section {
    margin-bottom: 50px;
}

.location-title {
    font-size: 1.2em;
    font-weight: bold;
    margin-bottom: 10px;
    color: #333;
}

.location-address {
    font-size: 1.1em;
    color: #555;
    display: flex;
    align-items: center;
}

.location-icon {
    font-size: 28px;
    color: #ff0000;
    margin-right: 10px;
    font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 28;
}

/* Sección de Redes Sociales */
.social-media-section {
    margin-bottom: 40px;
    text-align: left; /* Alineado a la izquierda por defecto en PC */
}

.social-title {
    font-size: 1.2em;
    font-weight: bold;
    margin-bottom: 20px;
    color: #333;
    text-align: left; /* Asegurar que el título también se alinee a la izquierda en PC */
}

.social-icons-wrapper {
    display: flex;
    justify-content: flex-start; /* Alineación a la izquierda en PC */
    gap: 25px; /* Espacio entre los iconos */
    background-color: transparent; /* Quitar la franja gris */
    padding: 0; /* Quitar padding de la franja */
    border-radius: 0; /* Quitar border-radius de la franja */
    box-shadow: none; /* Quitar sombra de la franja */
}

.social-icon-link {
    display: inline-block; /* Permite controlar width/height y centrar imagen */
    width: 50px; /* Tamaño del área del icono (círculo) */
    height: 50px;
    border-radius: 50%; /* Hacer el área circular si la imagen no lo es */
    overflow: hidden; /* Recortar si la imagen es más grande que el círculo */
    /* background-color: #ff0000;  Si quieres un fondo rojo detrás de la imagen (como un círculo sólido) */
    /* transition: background-color 0.3s ease; */ /* Si hay un color de fondo */
}

.social-icon-link:hover {
    /* background-color: #cc0000; */ /* Si hay un color de fondo */
    opacity: 0.8; /* Efecto de hover al pasar el mouse sobre la imagen */
}

.social-icon-img {
    width: 100%; /* La imagen ocupa todo el ancho del contenedor del enlace */
    height: 100%; /* La imagen ocupa todo el alto del contenedor del enlace */
    object-fit: contain; /* Asegura que la imagen se ajuste sin recortarse si es transparente */
    display: block; /* Elimina espacio extra debajo de la imagen */
}


.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* --- Media Queries para responsividad (versión móvil) --- */
@media (max-width: 768px) {
    #contacto h1 {
        font-size: 2.2em;
        text-align: center;
    }

    #contacto .subtitle {
        font-size: 1.2em;
        text-align: left;
    }

    .contact-form .form-row {
        flex-direction: column;
        gap: 15px;
    }

    .contact-form input[type="text"],
    .contact-form input[type="email"],
    .contact-form textarea {
        font-size: 1.05em;
    }

    .send-btn {
        width: 100%;
        font-size: 1em;
        padding: 10px 20px;
    }

    .location-title {
        font-size: 1.1em;
        text-align: left;
    }

    .location-address {
        font-size: 1em;
        justify-content: center;
    }

    .social-media-section {
        margin-bottom: 20px;
        text-align: left; /* Centrar sección en móvil */
    }

    .social-title {
        font-size: 1.1em;
        text-align: left; /* Centrar título en móvil */
    }

    .social-icons-wrapper {
        flex-wrap: wrap;
        justify-content: center; /* Alineación al centro en móvil */
        gap: 15px;
        padding: 0; /* Sin padding en móvil también */
    }

    .social-icon-link {
        width: 45px;
        height: 45px;
    }
    .social-icon-img {
        width: 100%;
        height: 100%;
        object-fit: contain; /* Asegura que las imágenes de los íconos mantengan su proporción */
    }
}

@media (max-width: 480px) {
    #contacto h1 {
        font-size: 2em;
    }
    #contacto .subtitle {
        font-size: 1em;
    }

    .contact-form input[type="text"],
    .contact-form input[type="email"],
    .contact-form textarea {
        font-size: 1em;
    }
    .send-btn {
        font-size: 0.95em;
    }
    .location-title {
        font-size: 1.3em;
    }
    .location-address {
        font-size: 0.95em;
    }
    .location-icon {
        font-size: 24px;
        font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24;
    }
    .social-title {
        font-size: 1.3em;
    }
    .social-icon-link {
        width: 40px;
        height: 40px;
    }
    .social-icon-img {
        width: 100%;
        height: 100%;
        object-fit: contain;
    }
}

/* ==========================================================================
Sección de Portafolio (Moment One: Type Selection)
========================================================================== */

/* Contenedor principal de la selección de tipos (Renders/Realizados) */
.portfolio-type-selection {
    display: flex; /* Convierte el contenedor en un contenedor flex */
    justify-content: space-between; /* Distribuye el espacio horizontalmente */
    align-items: center;
    width: 100%;
}

/* Cada ítem de selección (Renders o Realizados) */
.portfolio-type-item {
    display: block;
    width: 100vw;
    height: 70vh; /* Altura para el ítem */
    margin: 0;
    padding: 0;
    position: relative;
    overflow: hidden; /* Esto es clave para el recorte de imagen, manténgalo */
    text-decoration: none;
    color: inherit;
    box-sizing: border-box;
    border-radius: 0;
    transition: transform 0.3s ease;
}

.portfolio-type-item:hover {
    transform: scale(1.01);
    z-index: 6; /* Ligeramente superior a los ítems no-hovered */
}

/* Imagen dentro de cada ítem de tipo */
.portfolio-type-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 0;
}

/* Contenedor para el texto superpuesto */
.portfolio-text-overlay {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    background-color: rgba(0, 0, 0, 0.6);
    padding: 10px 15px;
    border-radius: 5px;
    text-align: center;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.portfolio-text-overlay h3 {
    color: white;
    font-size: 1.8em;
    margin: 0;
    font-weight: 700;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.8);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.portfolio-text-overlay p {
    color: white;
    font-size: 1em;
    margin: 5px 0 0 0;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ==========================================================================
Sección de Portafolio (Moment Two: Project Slider)
========================================================================== */

.project-slider-section {
 display: flex;
 flex-direction: column;
 align-items: center;
 padding: 20px;
 box-sizing: border-box;
 max-width: 1200px;
 margin: 0 auto; /* Usando 0 auto en lugar de 0px para centrar */
 width: 100%;
 position: relative; /* Contexto de apilamiento */
 z-index: 5; /* Asegura que esté por encima del contenido normal */
}

.project-slider-section.hidden {
 display: none;
}

.main-slider-container {
 position: relative;
 width: 100%;
 height: 500px;
 margin-bottom: 20px;
 overflow: hidden;
 display: flex;
 justify-content: center;
 align-items: center;
}

.main-slider-container img {
 width: 100%;
 height: auto;
 object-fit: contain;
 display: block;
 border-radius: 0;
 transition: transform 0.5s ease-out;
}

/* Animaciones */
@keyframes slideInRight {
 from { transform: translateX(100%); opacity: 0; }
 to { transform: translateX(0); opacity: 1; }
}

@keyframes slideInLeft {
 from { transform: translateX(-100%); opacity: 0; }
 to { transform: translateX(0); opacity: 1; }
}

.main-slider-container .slide-in-right { animation: slideInRight 2s forwards; }
.main-slider-container .slide-in-left { animation: slideInLeft 2s forwards; }

.slider-arrow {
 position: absolute;
 top: 50%;
 transform: translateY(-50%);
 background-color: rgba(0, 0, 0, 0.5);
 color: white;
 border: none;
 padding: 10px;
 cursor: pointer;
 font-size: 2em;
 z-index: 10; /* Encima de la imagen del slider */
 opacity: 0.8;
 transition: opacity 0.3s ease;
 border-radius: 50%;
 width: 50px;
 height: 50px;
 display: flex;
 justify-content: center;
 align-items: center;
}

.slider-arrow:hover { opacity: 1; }
.slider-arrow.left-arrow { left: 10px; }
.slider-arrow.right-arrow { right: 10px; }

.project-details {
 text-align: center;
 margin-bottom: 20px;
}

.project-details h3 { 
    font-size: 1.4em; 
    margin-bottom: 10px; 
}
.project-details p {
 font-size: 1.1em;
 line-height: 1.6;
 color: #555;
 max-width: 800px;
 margin: 0 auto;
}

/* Tira de miniaturas de proyectos */
.projects-thumbnail-strip-container {
 width: 100%;
 max-width: 800px;
 display: flex;
 align-items: center;
 margin-top: 15px;
 padding: 0;
 margin-bottom: 20px;
 background-color: transparent;
}

.projects-thumbnail-strip {
 display: flex;
 overflow-x: auto; /* Permite scroll horizontal */
 scroll-behavior: smooth;
 -webkit-overflow-scrolling: touch;
 white-space: nowrap;
 flex-grow: 1;
 padding: 0;
 margin: 0;
}

/* Scrollbar styling */
.projects-thumbnail-strip::-webkit-scrollbar { height: 8px; }
.projects-thumbnail-strip::-webkit-scrollbar-thumb { background: #ccc; border-radius: 4px; }
.projects-thumbnail-strip::-webkit-scrollbar-track { background: #f0f0f0; }

.project-thumbnail-item {
 flex-shrink: 0;
 width: 120px;
 height: 80px;
 margin: 0;
 padding: 0;
 border: 2px solid transparent;
 cursor: pointer;
 overflow: hidden;
 display: flex;
 justify-content: center;
 align-items: center;
 border-radius: 0;
 transition: border-color 0.3s ease;
}

.project-thumbnail-item + .project-thumbnail-item { margin-left: 0; }

.project-thumbnail-item.active { border: 5px solid; box-sizing: border-box; border-color: var(--primary-color, #ff5151); /* Fallback color */ }

.project-thumbnail-item img {
 width: 100%;
 height: 100%;
 object-fit: cover;
 display: block;
 border-radius: 0;
}

/* Flechas para la tira de miniaturas */
.projects-thumbnail-strip-container .thumbnail-arrow {
 background-color: rgba(0, 0, 0, 0.4);
 color: white;
 border: none;
 padding: 8px;
 cursor: pointer;
 font-size: 1.5em;
 z-index: 5;
 opacity: 0.7;
 transition: opacity 0.3s ease;
 border-radius: 50%;
 width: 40px;
 height: 40px;
 display: flex;
 justify-content: center;
 align-items: center;
 flex-shrink: 0;
}

.projects-thumbnail-strip-container .thumbnail-arrow:hover { opacity: 1; }
.projects-thumbnail-strip-container .thumbnail-left-arrow { margin-right: 5px; }
.projects-thumbnail-strip-container .thumbnail-right-arrow { margin-left: 5px; }

/* Botón de regresar */
.back-to-types-button {
 background-color: var(--primary-color, #ff0000); /* Fallback color si --primary-color no está definida */
 color: white;
 border: none;
 padding: 10px 20px;
 border-radius: 5px;
 cursor: pointer;
 font-size: 1.1em;
 margin-top: 20px;
 transition: background-color 0.3s ease;
}

.back-to-types-button:hover { background-color: #410000; }

/* ==========================================================================
Overlay de Zoom para Móviles (Portafolio)
========================================================================== */
.mobile-zoom-overlay {
 position: fixed;
 top: 0;
 left: 0;
 width: 100%;
 height: 100%;
 background-color: rgba(0, 0, 0, 0.9);
 display: flex;
 justify-content: center;
 align-items: center;
 z-index: 10000; /* Siempre por encima de todo */
}

.mobile-zoom-overlay.hidden { display: none; }

.mobile-zoom-overlay img { max-width: 90%; max-height: 90%; object-fit: contain; }

.close-zoom-button {
 position: absolute;
 top: 20px;
 right: 20px;
 background: none;
 border: none;
 color: white;
 font-size: 2em;
 cursor: pointer;
 z-index: 10001; /* Encima del overlay */
}

/* ==========================================================================
Estilos Responsive para Portafolio (Mobile)
========================================================================== */
@media (max-width: 768px) {
 .portfolio-type-selection { 
    flex-direction: column; 
}
  .portfolio-type-item {
    width: 100vw;
    height: 40vh;
  }
  
  #portafolio h1{
    font-size: 2em !important;
    text-align: center;
    margin-bottom: 30px;
  }
  
  .portfolio-text-overlay {
    bottom: 15px;
    padding: 8px 12px;
    width: 90%;
  }
  .portfolio-text-overlay h3 { font-size: 1.4em; }
  .portfolio-text-overlay p { font-size: 0.9em; margin-top: 3px; }

  .main-slider-container { 
    height: 300px; 
}
  .slider-arrow { display: none; }
  .projects-thumbnail-strip-container .thumbnail-arrow { display: none; }
  .projects-thumbnail-strip { justify-content: center; }
}

/* Estilo para ocultar elementos */
.hidden {
  display: none !important; /* ¡Es crucial! Fuerza al elemento a no mostrarse */
}


/* ==========================================================================
 Ajustes para la Sección de Portafolio: Full Width (y título)
 ========================================================================== */

/* Mantener esta regla para que la sección de portafolio se extienda a los bordes */
.container section#portafolio.main-section,
.editable-content section#portafolio.main-section {
  width: 100vw !important;
}

/* Ajustes específicos para el título "Portafolio" */
#portafolio h1{
    font-size: 3em;
    margin-bottom: 30px;
}
/* Contenedor principal de la paginación */
.pagination-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px; /* Espacio entre los botones */
    margin-top: 20px; /* Margen superior para separarlo del contenido del CV */
    font-family: Arial, sans-serif; /* O la fuente que uses en tu diseño */
}

/* Estilos generales para todos los botones de paginación (incluyendo Anterior/Siguiente y números) */
.pagination-controls button {
    background-color: #fff; /* Fondo blanco por defecto */
    color: #333; /* Texto oscuro por defecto */
    border: 1px solid #ccc; /* Borde gris claro por defecto */
    padding: 8px 12px;
    cursor: pointer;
    font-size: 1em;
    min-width: 35px; /* Ancho mínimo para que los números no sean demasiado pequeños */
    text-align: center;
    transition: all 0.2s ease-in-out; /* Transición suave para hover y estado activo */
    border-radius: 4px; /* Un poco de redondeo general */
}

/* Estilo para los botones de Anterior y Siguiente (flechas) */
.pagination-controls .prev-button,
.pagination-controls .next-button {
    font-weight: bold;
    font-size: 1.2em; /* Un poco más grandes para las flechas */
    padding: 8px 15px; /* Un poco más de padding lateral */
    border-radius: 4px; /* Mantener bordes redondeados */
}

/* Estilo para los botones numéricos */
.pagination-controls .page-button {
    border-radius: 4px; /* Ligeramente redondeados, puedes ajustar este valor */
}

/* Estado hover para todos los botones */
.pagination-controls button:hover:not(.active):not(:disabled) {
    background-color: #f0f0f0; /* Fondo ligeramente gris en hover */
    border-color: #999;
}

/* Estado deshabilitado para los botones Anterior/Siguiente */
.pagination-controls button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: #eee;
    color: #999;
}

/* Estilo para el botón de página ACTIVA (el rojo con bordes redondeados) */
.pagination-controls .page-button.active {
    background-color: #e4002b; /* Rojo */
    color: #fff; /* Texto blanco */
    border-color: #e4002b; /* Borde del mismo color */
    font-weight: bold;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2); /* Sutil sombra para destacarlo */
    border-radius: 8px; /* Más redondeado para que se parezca al de la imagen */
    transform: scale(1.05); /* Ligeramente más grande */
}

/* Quitar el borde de los botones numéricos por defecto si quieres que sean solo texto cuando no están activos */
/* Puedes comentar o eliminar esta regla si prefieres que siempre tengan un borde */
.pagination-controls .page-button:not(.active) {
    border: none;
    background-color: transparent;
    color: #333;
}

.pagination-controls .page-button:not(.active):hover {
    background-color: #f0f0f0;
}
