﻿.caja-principal-biografia {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    background-color: #7a3e35;
    width: 100%;
    height: 100vh;
    overflow: hidden;
    font-family: 'Rokkitt', serif;
}

.contenido-bio {
    flex: 1;
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    color: black;
    font-family: 'Rokkitt', serif;
}

    .contenido-bio h1 {
        font-size: 3rem;
        margin-bottom: 1rem;
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    }

    .contenido-bio h2 {
        font-size: 1.5rem;
    }

    .contenido-bio p {
        font-size: 1rem;
        line-height: 1.5;
        margin-bottom: 2rem;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }

/* Scroll personalizado para el texto expandido */
#bio-text.expanded {
    overflow-y: auto;
    scrollbar-color: rgba(0, 0, 0, 0.4) transparent;
}

    /* WebKit (Chrome, Edge, Safari) */
    #bio-text.expanded::-webkit-scrollbar {
        width: 2rem;
    }

    #bio-text.expanded::-webkit-scrollbar-track {
        /*background: transparent;*/
    }

    #bio-text.expanded::-webkit-scrollbar-thumb {
        background-color: rgba(0, 0, 0, 0.4);
        border-radius: 3px;
        transition: background-color 0.2s ease;
    }

        #bio-text.expanded::-webkit-scrollbar-thumb:hover {
            background-color: rgba(0, 0, 0, 0) !important;
        }

    /* 🔥 Estado activo forzado con clase */
    #bio-text.expanded.dragging::-webkit-scrollbar-thumb {
        background-color: #000 !important;
    }

/* Botones al final */
.botones-bio {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 2rem;
}

.volver-bio {
    background: none;
    border: none;
    color: black;
    font-size: 1rem;
    cursor: pointer;
}

    .volver-bio:hover {
        text-decoration: underline;
    }

.ver-mas {
    font-size: 1rem;
    color: black;
    cursor: pointer;
    font-weight: bold;
}

    .ver-mas:hover {
        text-decoration: underline;
    }

/* Franja decorativa */
.agenda-full-width-image {
    width: calc(100% + 10rem);
    height: 3rem;
    margin-left: -6rem;
}

/* Imagen lateral derecha */
.imagen-container {
    flex: 1;
    width: 50%;
    height: 100%;
    overflow: hidden;
    display: block;
}

.imagen-bio {
    background-image: url('/images/biografia/imagen.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    width: 100%;
    height: 100%;
}

/* --- RESPONSIVE --- */
@media (max-width: 991px) {
    .caja-principal-biografia {
        flex-direction: column;
        height: auto;
    }

    .contenido-bio {
        padding: 2rem;
        text-align: center;
    }

        .contenido-bio h1 {
            font-size: 2.5rem;
            margin-bottom: 0.5rem;
        }

        .contenido-bio h2 {
            font-size: 1.3rem;
            margin-bottom: 1rem;
        }

        .contenido-bio p {
            font-size: 1rem;
            line-height: 1.4;
            margin-bottom: 1.5rem;
        }

    #bio-text.expanded {
        max-height: 300px;
    }

    .imagen-container {
        width: 100%;
        min-height: 500px;
        height: auto;
    }

    .imagen-bio {
        height: 100%;
        min-height: 500px;
        background-size: cover;
    }

    .botones-bio {
        flex-direction: row;
        justify-content: space-between;
        padding-top: 1.5rem;
    }

    .volver-bio,
    .ver-mas {
        font-size: 1rem;
    }
}

@media (max-width: 576px) {
    .contenido-bio h1 {
        font-size: 2rem;
    }

    .contenido-bio h2 {
        font-size: 1.1rem;
    }

    .contenido-bio p {
        font-size: 0.9rem;
    }

    #bio-text.expanded {
        max-height: 250px;
    }

    .imagen-container {
        min-height: 200px;
        height: auto;
    }

    .botones-bio {
        flex-direction: row;
        justify-content: space-between;
        padding-top: 1rem;
    }
}
