/* Importar la fuente Source Sans 3 */
@import url('https://fonts.googleapis.com/css2?family=Source+Sans+3:wght@400;600;700;800&display=swap');

/* Base */
.cecofersa-catalogo {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    font-family: 'Source Sans 3', sans-serif;
    color: #333;
}

.cecofersa-catalogo .content-container {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
}

/* Header */
.cecofersa-catalogo .site-header {
    background-color: #fff;
    padding: 10px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-left: 10%;
    margin-right: 10%;
}

.cecofersa-catalogo .site-branding {
    display: flex;
    align-items: center;
}

.cecofersa-catalogo .custom-logo-link img {
    max-height: 80px;
    width: auto;
}

.cecofersa-catalogo .main-navigation {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.cecofersa-catalogo .menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

.cecofersa-catalogo .menu-principal-container {
    display: flex;
}

.cecofersa-catalogo .menu-principal-container ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
}

.cecofersa-catalogo .menu-principal-container ul li {
    margin: 0 15px;
}

.cecofersa-catalogo .menu-principal-container ul li a {
    text-decoration: none;
    color: #333;
    font-weight: bold;
    display: flex;
    align-items: center;
}

/* Título */
.cecofersa-catalogo .page-title {
    text-align: center;
    color: #e85412;
    margin-bottom: 20px;
    margin-left: 10%;
    margin-right: 10%;
}

.cecofersa-catalogo .page-title h1 {
    margin: 0;
    font-size: 2.2em;
    font-weight: 800;
    text-transform: uppercase;
    font-family: 'Source Sans 3', sans-serif;
}

/* CONTADORES - estilo tarjetas */
.cecofersa-catalogo #counters {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin: 15px 0;
    background: transparent;
    padding: 0;
    border: none;
    box-shadow: none;
}



/* Tarjeta individual */
.cecofersa-catalogo .counter {
    background: #fff;
    border-radius: 6px;
    padding: 10px 8px;
    text-align: center;

    /* línea gris más marcada */
    border: 1px solid #d0d0d0;

    box-shadow: none;
}

/* Hover suave */
.cecofersa-catalogo .counter:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
}

/* Número */
.cecofersa-catalogo .counter span {
    display: block;
    font-size: 22px;
    font-weight: 800;
    color: #e85412;
    line-height: 1.2;
}

/* Texto */
.cecofersa-catalogo .counter p {
    margin: 0;
    font-size: 13px;
    color: #666;
}

/* Filtros */
.cecofersa-catalogo #search-filters {
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;
    width: 100%;
    margin-bottom: 20px;
    background-color: #fff;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    box-sizing: border-box;
}

.cecofersa-catalogo #search-filters input,
.cecofersa-catalogo #search-filters select,
.cecofersa-catalogo #search-filters button {
    margin-right: 10px;
    padding: 10px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 5px;
}

.cecofersa-catalogo #search-filters select {
    cursor: pointer;
}

.cecofersa-catalogo #search-filters button {
    cursor: pointer;
    flex: 0 0 auto;
    margin: 5px;
}

.cecofersa-catalogo #search-filters select[multiple] {
    height: auto;
    min-height: 100px;
    width: 200px;
}

.cecofersa-catalogo #searchInput {
    width: 100%;
    flex-grow: 1;
    box-sizing: border-box;
    margin-right: 10px;
    margin-bottom: 10px;
}

#search-filters > select,
.cecofersa-catalogo #search-filters > button {
    margin-top: 5px;
    font-family: 'Source Sans 3', sans-serif;
}

.cecofersa-catalogo .clear-filters-button,
.cecofersa-catalogo .export-excel-button {
    flex-basis: calc(50% - 5px);
    margin-right: 0;
}

.cecofersa-catalogo .clear-filters-button {
    margin-right: 5px;
}

.cecofersa-catalogo #clearFilters {
    background-color: #f4cccc;
    padding: 10px 15px;
    font-size: 16px;
}

.cecofersa-catalogo #exportExcel,
.cecofersa-catalogo #exportExcelWithImages,
.cecofersa-catalogo #exportPDF {
    background-color: #D2E2D9;
    padding: 10px 15px;
    font-size: 16px;
}

/* Tabla */
.cecofersa-catalogo table {
    width: 100%;
    border-collapse: collapse !important;
    margin-bottom: 20px;
    background-color: #fff;
    border: 0 !important;
    outline: 0 !important;
    box-shadow: none !important;
}

.cecofersa-catalogo table thead,
.cecofersa-catalogo table tbody,
.cecofersa-catalogo table tr,
.cecofersa-catalogo table th,
.cecofersa-catalogo table td {
    border-top: 0 !important;
    border-left: 0 !important;
    outline: 0 !important;
    box-shadow: none !important;
}

.cecofersa-catalogo th,
.cecofersa-catalogo td {
    padding: 10px;
    border: none !important;
    text-align: left;
    vertical-align: middle;
}

.cecofersa-catalogo th {
    background-color: #e85412;
    color: #fff;
    border-bottom: 1px solid #d84d10 !important;
}

.cecofersa-catalogo td {
    border-bottom: 1px solid #ddd !important;
}

.cecofersa-catalogo tbody tr:last-child td {
    border-bottom: none !important;
}

.cecofersa-catalogo td img {
    display: block;
    margin: 0 auto;
}

/* Columnas específicas */
.cecofersa-catalogo table th.col-logotipo,
.cecofersa-catalogo table td.col-logotipo {
    width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cecofersa-catalogo table td.col-logotipo img {
    max-width: 100px;
    max-height: 100px;
    width: 100%;
    height: auto;
}

.cecofersa-catalogo table th.col-imagen,
.cecofersa-catalogo table td.col-imagen {
    width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cecofersa-catalogo table td.col-imagen img.imagen-producto {
    max-width: 150px;
    max-height: 150px;
    width: 100%;
    height: auto;
}

/* Imágenes */
.cecofersa-catalogo img {
    max-width: 150px;
    max-height: 150px;
    width: auto;
    height: auto;
    cursor: pointer;
}

.cecofersa-catalogo .product-image {
    display: block;
    margin-left: auto;
    margin-right: auto;
    max-height: 100px;
    object-fit: contain;
}

.cecofersa-catalogo .imagen-producto {
    max-width: 200px;
    max-height: 200px;
    width: 100%;
    height: auto;
}

/* Paginación */
.cecofersa-catalogo .pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 20px 0;
}

.cecofersa-catalogo .pagination a,
.cecofersa-catalogo .pagination span {
    margin: 0 5px;
    padding: 10px 20px;
    text-decoration: none;
    border: 1px solid #ccc;
    border-radius: 5px;
    background-color: #e85412;
    color: white;
    cursor: pointer;
}

.cecofersa-catalogo .pagination .active {
    background-color: #b7400e;
    color: white;
    border-color: #b7400e;
}

/* Mensaje sin datos */
.cecofersa-catalogo #noDataMessage {
    display: none;
    font-size: 1.2em;
    text-align: center;
    background-color: #FCCCA4;
    color: #721c24;
    border: 1px solid #e85412;
    border-radius: 4px;
    padding: 20px;
    margin: 20px 0;
}

/* Popup */
.cecofersa-catalogo .popup {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
}

.cecofersa-catalogo .popup-content {
    background-color: #fff;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 600px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    text-align: center;
}

.cecofersa-catalogo .close-popup {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.cecofersa-catalogo .close-popup:hover,
.cecofersa-catalogo .close-popup:focus {
    color: #000;
    text-decoration: none;
    cursor: pointer;
}

/* Modal */
.cecofersa-catalogo .modal {
    display: none;
    position: fixed;
    z-index: 1001;
    padding-top: 100px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.9);
}

.cecofersa-catalogo .modal-content {
    display: block;
    margin: auto;
    width: 80%;
    max-width: 700px;
    max-height: 80vh;
    object-fit: contain;
}

.cecofersa-catalogo #caption {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 700px;
    text-align: center;
    color: #ccc;
    padding: 10px 0;
    height: 150px;
}

.cecofersa-catalogo .modal-content,
.cecofersa-catalogo #caption {
    animation-name: zoom;
    animation-duration: 0.6s;
}

@keyframes zoom {
    from { transform: scale(0); }
    to { transform: scale(1); }
}

.cecofersa-catalogo .close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
}

.cecofersa-catalogo .close:hover,
.cecofersa-catalogo .close:focus {
    color: #bbb;
    text-decoration: none;
    cursor: pointer;
}

/* Utilidades */
.cecofersa-catalogo .no-shadow {
    box-shadow: none !important;
    background-color: #fff !important;
}

.ceco-desc-wrap {
    display: block;
}

.ceco-desc-toggle {
    all: unset;
    display: inline;
    cursor: pointer;
    color: #f28c00;
    font-size: 12px;
    text-decoration: underline;
}

.ceco-desc-toggle:hover {
    opacity: 0.8;
}

.ceco-desc-toggle:focus,
.ceco-desc-toggle:active {
    outline: none;
    box-shadow: none;
}

.cecofersa-catalogo footer {
    display: none;
}

/* Responsive */
@media (max-width: 768px) {

    .cecofersa-catalogo .menu-toggle {
        display: block;
    }

    .cecofersa-catalogo .menu-principal-container {
        display: none;
    }

    #exportPDF,
    #exportExcel,
    .cecofersa-catalogo #exportExcelWithImages {
        display: none;
    }

    .cecofersa-catalogo .site-header {
        margin-left: 5%;
        margin-right: 5%;
    }

    .cecofersa-catalogo #search-filters {
        flex-direction: column;
        align-items: stretch;
    }

    .cecofersa-catalogo #search-filters input,
    .cecofersa-catalogo #search-filters select,
    .cecofersa-catalogo #search-filters button {
        width: 100%;
        margin-right: 0;
        margin-bottom: 10px;
    }

    .cecofersa-catalogo #searchInput {
        margin-right: 0;
        margin-bottom: 10px;
    }
}

/* Print */
@media print {
    .cecofersa-catalogo .content-container {
        padding-left: 2mm;
        padding-right: 2mm;
        width: auto !important;
        margin: auto !important;
    }

    .cecofersa-catalogo #counters,
    .cecofersa-catalogo #search-filters,
    .cecofersa-catalogo .menu-principal-container {
        display: none !important;
    }

    .cecofersa-catalogo .content-container,
    .cecofersa-catalogo .page-title {
        width: 100% !important;
        margin: 0 !important;
    }

    .cecofersa-catalogo table {
        width: 100%;
        border-collapse: collapse !important;
        margin-bottom: 20px;
        border: 0 !important;
        box-shadow: none !important;
    }

    .cecofersa-catalogo th,
    .cecofersa-catalogo td {
        padding: 10px;
        font-size: 12px;
        text-align: left;
        vertical-align: middle;
        border: 1px solid #ddd !important;
    }

    .cecofersa-catalogo th {
        background-color: #e85412 !important;
        color: #fff !important;
    }

    .cecofersa-catalogo td img {
        display: block;
        margin: 0 auto;
        max-height: 100px;
        max-width: 100px;
    }

    .cecofersa-catalogo .page-title h1 {
        color: #e85412;
        font-size: 24px;
        font-weight: 800;
    }

    .cecofersa-catalogo th:nth-child(2),
    .cecofersa-catalogo td:nth-child(2) {
        width: 5%;
    }

    .cecofersa-catalogo footer {
        display: block;
        position: fixed;
        bottom: 0;
        width: 100%;
        text-align: center;
        font-size: 10px;
        color: #333;
        padding: 5px 0;
        background-color: #fff;
    }
}

@media (max-width: 480px) {
    .cecofersa-catalogo #counters {
        grid-template-columns: 1fr;
    }
}

.cecofersa-catalogo #clearFilters,
.cecofersa-catalogo #exportPDF,
.cecofersa-catalogo #exportExcel,
.cecofersa-catalogo #exportExcelWithImages {
    opacity: 1 !important;
    background-image: none !important;
    box-shadow: none !important;
    filter: none !important;
    color: #fff !important;
    border: none !important;
}

.cecofersa-catalogo #clearFilters {
    background: #e85412 !important;
}

.cecofersa-catalogo #exportPDF,
.cecofersa-catalogo #exportExcel,
.cecofersa-catalogo #exportExcelWithImages {
    background: #6f8f7f !important;
}