/* ===============================================
   STREAMFIELD BLOCKS CSS - COCEPU
   Estilos para bloques de contenido dinámico
   =============================================== */

/* Heading Block */
.content-heading {
    font-size: 1.8rem;
    color: var(--gray-dark);
    margin: 35px 0 20px;
    font-weight: 700;
    line-height: 1.3;
}

/* Paragraph Block */
.content-paragraph {
    margin-bottom: 20px;
}

.content-paragraph p {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--gray-dark);
    margin-bottom: 15px;
}

.content-paragraph strong {
    font-weight: 700;
    color: var(--gray-dark);
}

.content-paragraph em {
    font-style: italic;
}

.content-paragraph a {
    color: var(--primary-green);
    text-decoration: underline;
    transition: color 0.3s ease;
}

.content-paragraph a:hover {
    color: var(--primary-dark);
}

/* Image Block */
.content-image {
    margin: 30px 0;
}

.content-image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* Image with Caption Block */
.content-image-caption {
    margin: 30px 0;
}

.content-image-caption img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 10px;
}

.content-image-caption figcaption {
    text-align: center;
    font-size: 0.9rem;
    color: var(--gray-medium);
    font-style: italic;
    padding: 0 20px;
}

/* Quote Block */
.content-quote {
    border-left: 5px solid var(--primary-green);
    padding: 20px 30px;
    margin: 30px 0;
    background: var(--gray-light);
    border-radius: 0 12px 12px 0;
    font-size: 1.15rem;
    font-style: italic;
    color: var(--gray-dark);
    position: relative;
}

.content-quote::before {
    content: '"';
    font-size: 4rem;
    color: var(--primary-green);
    opacity: 0.2;
    position: absolute;
    top: 10px;
    left: 10px;
    font-family: Georgia, serif;
}

.content-quote p {
    margin: 0;
    position: relative;
    z-index: 1;
}

/* Embed Block */
.content-embed {
    margin: 30px 0;
    position: relative;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.content-embed iframe,
.content-embed object,
.content-embed embed {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 12px;
}

/* Gallery Block */
.content-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin: 30px 0;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: scale(1.03);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

/* Listas en rich text */
.content-paragraph ul,
.content-paragraph ol {
    margin: 20px 0;
    padding-left: 30px;
}

.content-paragraph ul li,
.content-paragraph ol li {
    margin-bottom: 10px;
    line-height: 1.7;
}

.content-paragraph ul li {
    list-style-type: disc;
}

.content-paragraph ol li {
    list-style-type: decimal;
}

/* Tablas en rich text */
.content-paragraph table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.content-paragraph table th {
    background: var(--primary-green);
    color: var(--white);
    padding: 12px;
    text-align: left;
    font-weight: 600;
}

.content-paragraph table td {
    padding: 12px;
    border-bottom: 1px solid var(--gray-light);
}

.content-paragraph table tr:last-child td {
    border-bottom: none;
}

.content-paragraph table tr:hover {
    background: var(--gray-light);
}

/* Responsive */
@media (max-width: 768px) {
    .content-heading {
        font-size: 1.5rem;
    }

    .content-quote {
        padding: 15px 20px;
        font-size: 1rem;
    }

    .content-gallery {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 10px;
    }

    .content-embed {
        margin: 20px 0;
    }
}

@media (max-width: 480px) {
    .content-heading {
        font-size: 1.3rem;
    }

    .content-paragraph p {
        font-size: 1rem;
    }

    .content-gallery {
        grid-template-columns: 1fr;
    }
}
