.ddh-contenedor-global {
    width: 100%;
    display: flex;
    justify-content: center;
    padding-bottom: 2em;
}

@media (max-width: 1700px) {
    .primera-column-pagina:not(:has(.contenedor-flecha-primera-columna.column-abierta)) .ddh-contenedor-global.oculta-primera-columna {
        display: none !important;
    }
}

.ddh-layout {
    width: 100%;
    max-width: 84em;
    display: flex;
    gap: 1.5em;
    align-items: flex-start;
}

.ddh-col-izquierda {
    flex: 0 0 22em;
}

.ddh-col-derecha {
    flex: 1;
    min-width: 0;
}

.ddh-contenedor-form {
    width: 100%;
    display: flex;
    justify-content: center;
}

.ddh-formulario {
    display: flex;
    flex-direction: column;
    gap: 1em;
    max-width: 100%;
    width: 22em;
    border: none;
    border-radius: 8px;
    padding: 1.1em;
    box-sizing: border-box;
    font-size: 1em;
    background-color: #ededed;
    border-top: 1px solid #e1e1e18f;
        margin-bottom: 5em;
}

.ddh-titulo {
    text-align: center;
    color: #000000;
    font-size: 1.1em;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.ddh-formulario .texto-titulo,
.ddh-panel-seleccion .texto-titulo,
.ddh-panel-titulo {
    color: #000000;
}

.ddh-selector-bloque {
    background-color: #ffffff;
    border-radius: 20px;
    overflow: hidden;
}

.ddh-selector-contenido {
    display: none;
    padding: 1em;
    margin-top: 0;
    gap: 0.65em;
    flex-direction: column;
}

.ddh-selector-bloque.abierto .ddh-selector-contenido {
    display: flex;
}

.ddh-bloque {
    background-color: #ffffff;
    border-radius: 20px;
    padding: 0.8em;
    display: flex;
    flex-direction: column;
    gap: 0.5em;
}

.ddh-bloque-fechas {
    gap: 0.75em;
}

.ddh-filas-fecha {
    display: flex;
    gap: 0.8em;
    align-items: flex-end;
    justify-content: space-between;
}

.ddh-campo-fecha {
    width: 48%;
    display: flex;
    flex-direction: column;
    gap: 0.2em;
}

.ddh-campo-fecha label {
    font-size: 0.9em;
}

.ddh-campo-fecha input[type="date"] {
    border: 1px solid #aaaaaa;
    border-radius: 3px;
    color: #707070;
    cursor: text;
    font-size: 95%;
    width: 100%;
    min-height: 2.1em;
    padding: 0.15em 0.3em;
    box-sizing: border-box;
}

.ddh-campo-fecha input[type="date"]::-webkit-calendar-picker-indicator {
    cursor: pointer;
}

.ddh-select,
.ddh-input-texto {
    border-radius: 20px;
    border: 1px solid #d8d8d8;
    color: #000000;
    font-weight: bold;
    width: 100%;
    padding: 0.45em 0.75em;
    min-height: 2.3em;
    box-sizing: border-box;
    background-color: #ffffff;
}

.ddh-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url('../historico-avisos/images/flecha.svg');
    background-repeat: no-repeat;
    background-size: 0.95em;
    background-position: right 0.7em center;
    padding-right: 2em;
}

.ddh-select::-ms-expand {
    display: none;
}

.ddh-select:focus,
.ddh-input-texto:focus {
    outline: none;
    border-color: #0067b2;
    box-shadow: none;
}

.ddh-buscador-wrap {
    position: relative;
}

.ddh-checkbox-list {
    display: flex;
    flex-direction: column;
    gap: 0.5em;
   margin-top: 0 !important;
    font-size: 0.9em;
    width: 100%;
    box-sizing: border-box;
}

.ddh-check-item {
    display: block;
    width: 100%;
    line-height: normal;
}

.ddh-check-item label,
.ddh-check-item input {
    cursor: pointer;
}

.ddh-check-item input {
    margin: 0 0.3em 0 0;
   
}

.ddh-check-item label {
    display: inline;
    font-size: inherit;
    font-weight: inherit;
    color: #000000;
    word-break: break-word;
}

.ddh-checkbox-list-estaciones {
    max-height: 17em;
    overflow-y: auto;
    padding-right: 0.25em;
}

.ddh-buscador-wrap {
        margin-bottom: 1em;
}

.ddh-formatos {
    display: flex;
    gap: 0.6em;
    justify-content: flex-start;
    flex-wrap: wrap;
}

.ddh-formato-item {
    display: inline-flex;
    align-items: center;
    gap: 0.4em;
    border: 1px solid #d6d6d6;
    border-radius: 12px;
    padding: 0.35em 0.7em;
    cursor: pointer;
    color: #4f4f4f;
    font-size: 0.9em;
}

.ddh-formato-item input {
    margin: 0;
}

.ddh-botones {
    margin-top: 0.2em;
}

#ddh-btn-anadir-senal,
#ddh-btn-descargar {
    border: none;
    border-radius: 15px;
    margin: 0 auto;
    background-color: #0067b2d6;
    color: #ffffff;
    font-size: 1.1em;
    font-weight: bold;
    padding-top: 0.5em;
    padding-bottom: 0.5em;
    cursor: pointer;
}

#ddh-btn-anadir-senal {
    width: 45%;
}

#ddh-btn-descargar {
    width: 100%;
    max-width: 18em;
}

#ddh-btn-anadir-senal:hover,
#ddh-btn-descargar:hover {
    background-color: #005c9f;
}

#ddh-btn-descargar:disabled {
    background-color: #8cb4d0;
    cursor: not-allowed;
}

.ddh-ayuda {
    margin: 0;
    font-size: 0.83em;
    color: #5f5f5f;
    line-height: 1.35;
}

.ddh-panel-seleccion {
display: flex;
    flex-direction: column;
    gap: 0.9em;
    background-color: #ededed;
    border-top: 1px solid #e1e1e18f;
    border-radius: 8px;
    padding: 1.1em;
    min-height: 20em;
       width: 80%;
    margin: 0 auto;
    margin-top: 1em;
}

.ddh-panel-titulo {
    color: #0a67b1;
    font-size: 1.1em;
    letter-spacing: 0.02em;
}

.ddh-panel-vacio {
    background-color: #ffffff;
    border-radius: 12px;
    border: 1px dashed #cfd8df;
    color: #5e5e5e;
    padding: 0.85em;
    font-size: 0.92em;
}

.ddh-lista-senales {
    display: flex;
    flex-direction: column;
    gap: 0.7em;
    max-height: 22em;
    overflow-y: auto;
}

.ddh-item-senal {
    background-color: #ffffff;
    border: 1px solid #e1e1e1;
    border-radius: 12px;
    padding: 0.75em 0.8em;
}

.ddh-item-cabecera {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.7em;
}

.ddh-item-titulo {
    margin: 0;
    color: #0a67b1;
    font-weight: bold;
    line-height: 1.25;
}

.ddh-item-detalles {
    margin-top: 0.45em;
    display: flex;
    flex-wrap: wrap;
    gap: 0.45em;
}

.ddh-chip {
    display: inline-flex;
    align-items: center;
    border: 1px solid #d5e7f5;
    background-color: #f1f8ff;
    color: #35566f;
    border-radius: 999px;
    padding: 0.2em 0.65em;
    font-size: 0.82em;
}

.ddh-btn-eliminar-senal {
    border: 1px solid #d5d5d5;
    background-color: #ffffff;
    color: #606060;
    border-radius: 999px;
    padding: 0.2em 0.7em;
    font-size: 0.8em;
    cursor: pointer;
    white-space: nowrap;
}

.ddh-btn-eliminar-senal:hover {
    border-color: #a0a0a0;
    color: #2f2f2f;
}

.ddh-bloque-descarga {
    margin-top: auto;
}

.ddh-botones-descarga {
    margin-top: 0.4em;
}

.ddh-mensaje-estado {
    display: none;
    border-radius: 10px;
    padding: 0.6em 0.7em;
    font-size: 0.88em;
}

.ddh-mensaje-estado.info {
    display: block;
    color: #1c4f6e;
    background-color: #eaf4fc;
}

.ddh-mensaje-estado.error {
    display: block;
    color: #842029;
    background-color: #f8d7da;
}

.ddh-mensaje-estado.ok {
    display: block;
    color: #0f5132;
    background-color: #d1e7dd;
}

.ddh-mensaje-progreso-cabecera {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
}

.ddh-mensaje-progreso-texto {
    min-width: 0;
    line-height: 1.35;
}

.ddh-mensaje-progreso-valor {
    flex: 0 0 auto;
    font-weight: 800;
}

.ddh-mensaje-progreso-barra {
    width: 100%;
    height: 0.42rem;
    margin-top: 0.55rem;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.72);
}

.ddh-mensaje-progreso-relleno {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #0067b2;
    transition: width 0.22s ease;
}

.ddh-mensaje-progreso-barra-indeterminada .ddh-mensaje-progreso-relleno {
    width: 42%;
    animation: ddh-progreso-indeterminado 1.15s ease-in-out infinite;
    transition: none;
}

@keyframes ddh-progreso-indeterminado {
    0% {
        transform: translateX(-120%);
    }

    100% {
        transform: translateX(240%);
    }
}

@media (prefers-reduced-motion: reduce) {
    .ddh-mensaje-progreso-barra-indeterminada .ddh-mensaje-progreso-relleno {
        width: 100%;
        animation: none;
        opacity: 0.45;
    }
}

.ddh-mensaje-estado.ok .ddh-mensaje-progreso-relleno {
    background: #198754;
}

.ddh-mensaje-estado.error .ddh-mensaje-progreso-relleno {
    background: #842029;
}

.ddh-resumen-descarga {
    display: grid;
    gap: 0.55rem;
    margin-top: 0.65rem;
}

.ddh-resumen-grupo {
    display: grid;
    gap: 0.25rem;
}

.ddh-resumen-titulo {
    font-weight: 800;
}

.ddh-resumen-lista {
    display: grid;
    gap: 0.18rem;
    margin: 0;
    padding-left: 1.15rem;
}

.ddh-resumen-lista li {
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.ddh-resumen-extra {
    font-style: italic;
    opacity: 0.82;
}

/* Refresh visual alineado con la linea de estadisticas del plugin principal. */
.ddh-formulario,
.ddh-panel-seleccion {
    background: transparent;
    border-top: 0;
    border-radius: 12px;
    box-shadow: none;
}

.ddh-titulo,
.ddh-panel-titulo,
.ddh-formulario .texto-titulo,
.ddh-panel-seleccion .texto-titulo {
    color: #0067b2d6;
    font-weight: 700;
}

.ddh-titulo,
.ddh-panel-titulo {
    letter-spacing: 0.02em;
}

.ddh-selector-bloque,
.ddh-bloque,
.ddh-panel-vacio,
.ddh-item-senal {
    background: #ffffff;
    border: 1px solid #dce8f3;
    border-radius: 12px;
    box-shadow: none;
}

.ddh-selector-bloque {
    overflow: hidden;
}

.ddh-selector-toggle,
.ddh-selector-contenido,
.ddh-bloque,
.ddh-item-senal {
    box-sizing: border-box;
}

.ddh-selector-toggle {
    align-items: center;
    border-radius: 12px;
    padding: 0.78em 0.9em;
    transition: background-color 0.2s ease;
}

.ddh-selector-toggle:hover {
    background: rgba(0, 103, 178, 0.045);
}

.ddh-selector-bloque.abierto .ddh-selector-toggle {
    border-bottom: 1px solid #e4edf5;
    border-bottom-right-radius: 0;
    border-bottom-left-radius: 0;
    background: #f8fbfe;
}

.ddh-selector-contenido {
    padding: 0.85em 0.9em 1em;
}

.ddh-input-texto,
.ddh-select,
.ddh-campo-fecha input[type="date"] {
    border: 1px solid #d4e2ef;
    border-radius: 8px;
    background: #ffffff;
    color: #405972;
    font-weight: 600;
    min-height: 2.35em;
}

.ddh-input-texto:focus,
.ddh-select:focus,
.ddh-campo-fecha input[type="date"]:focus {
    border-color: #8cb8da;
    box-shadow: 0 0 0 3px rgba(0, 103, 178, 0.09);
    outline: none;
}

.ddh-check-item {
    padding: 0.16em 0;
}

.ddh-check-item label {
    color: #405972;
    font-weight: 600;
}

.ddh-bloque {
    padding: 0.9em;
}

.ddh-campo-fecha label {
    color: #5e758d;
    font-weight: 600;
}

.ddh-formatos {
    gap: 0.5em;
}

.ddh-formato-item {
    border: 1px solid #d4e2ef;
    border-radius: 8px;
    background: #ffffff;
    color: #405972;
    font-weight: 600;
    transition: border-color 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.ddh-formato-item:has(input:checked) {
    border-color: #0067b2;
    background: #eaf5fd;
    color: #0067b2;
}

.ddh-panel-vacio {
    background: #f8fbfe;
    border-style: solid;
    color: #5e758d;
}

.ddh-item-senal {
    padding: 0.85em 0.9em;
}

.ddh-item-titulo {
    color: #0067b2d6;
}

.ddh-chip {
    border: 1px solid #d4e2ef;
    background: #ffffff;
    color: #405972;
    border-radius: 7px;
    font-weight: 600;
}

.ddh-btn-eliminar-senal {
    border: 1px solid #d4e2ef;
    background: #ffffff;
    color: #4d6170;
    font-weight: 600;
}

.ddh-btn-eliminar-senal:hover {
    border-color: #8cb8da;
    color: #0067b2;
}

#ddh-btn-anadir-senal,
#ddh-btn-descargar {
    border-radius: 8px;
    background: #0067b2d6;
    box-shadow: none;
}

#ddh-btn-anadir-senal:hover,
#ddh-btn-descargar:hover {
    background: #005c9f;
}

.ddh-ayuda {
    color: #5e758d;
}

@media (max-width: 1000px) {
    .ddh-layout {
        flex-direction: column;
    }

    .ddh-col-izquierda,
    .ddh-col-derecha {
        flex: 1 1 auto;
        width: 100%;
    }

    .ddh-formulario,
    .ddh-panel-seleccion {
        width: 100%;
        max-width: none;
    }
}

@media (max-width: 600px) {
    .ddh-formulario,
    .ddh-panel-seleccion {
        padding: 0.8em;
    }

    .ddh-filas-fecha {
        flex-direction: column;
        align-items: stretch;
    }

    .ddh-campo-fecha {
        width: 100%;
    }

    #ddh-btn-anadir-senal,
    #ddh-btn-descargar {
        width: 100%;
        max-width: none;
    }

    .ddh-item-cabecera {
        flex-direction: column;
    }
}

/* Maqueta descarga historicos: filtros laterales y panel principal. */
.ddh-layout {
    max-width: 96rem;
    gap: 1.55rem;
    align-items: flex-start;
}

.ddh-col-izquierda {
    flex: 0 0 24rem;
}

.ddh-col-derecha {
    flex: 1 1 auto;
    min-width: 0;
}

.ddh-contenedor-global {
    justify-content: flex-start;
    padding-bottom: 0;
}

.ddh-contenedor-form {
    justify-content: flex-start;
}

.ddh-formulario {
    width: 100%;
    max-width: 24rem;
    gap: 0;
    margin: 0;
    padding: 0;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #dbe4ee;
    border-radius: 8px;
    box-shadow: 0 12px 26px rgba(17, 45, 75, 0.08);
}

.ddh-formulario > .ddh-titulo,
.ddh-panel-seleccion > .ddh-panel-titulo {
    display: none;
}

.ddh-filtros-cabecera {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    min-height: 3.45rem;
    padding: 0.95rem 1.18rem;
    border-bottom: 1px solid #dbe4ee;
    color: #0067b2;
    box-sizing: border-box;
}

.ddh-filtros-cabecera .ddh-titulo {
    display: inline;
    margin: 0;
    color: #0067b2;
    font-size: 1rem;
    line-height: 1.2;
    letter-spacing: 0;
    text-align: left;
}

.ddh-icono-filtro {
    display: inline-block;
    width: 1.15rem;
    height: 1.15rem;
    flex: 0 0 1.15rem;
    background: url("images/filtrar.svg") center / contain no-repeat;
}

.ddh-selector-bloque {
    margin: 0;
    overflow: hidden;
    background: #ffffff;
    border: 0;
    border-bottom: 1px solid #dbe4ee;
    border-radius: 0;
    box-shadow: none;
}

.ddh-selector-bloque:last-of-type {
    border-bottom: 0;
}

.ddh-ayuda {
    display: none;
}

.ddh-formulario > .ddh-botones {
    display: flex;
    justify-content: center;
    margin: 0;
    padding: 0 1.18rem 1.15rem;
}

.ddh-selector-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.18rem 0.72rem;
    border-radius: 0;
    background: #ffffff;
    box-sizing: border-box;
}

.ddh-selector-toggle:hover,
.ddh-selector-bloque.abierto .ddh-selector-toggle {
    background: #ffffff;
    border-bottom: 0;
}

.ddh-formulario .texto-titulo,
.ddh-panel-seleccion .texto-titulo,
.ddh-panel-titulo,
.ddh-panel-titulo-nuevo {
    color: #003b73;
    font-weight: 700;
}

.ddh-selector-toggle .texto-titulo {
    display: flex;
    align-items: center;
    gap: 0.42rem;
    margin: 0;
    color: #004f9e;
    font-size: 0.94rem;
    line-height: 1.2;
}

.ddh-flecha-selector {
    width: 0.72rem;
    height: 0.72rem;
    object-fit: contain;
    filter: invert(30%) sepia(85%) saturate(1587%) hue-rotate(184deg) brightness(89%) contrast(95%);
}

.ddh-selector-contenido {
    display: none;
    padding: 0 1.18rem 1.12rem;
    margin: 0;
    gap: 0.55rem;
    box-sizing: border-box;
}

.ddh-selector-bloque.abierto .ddh-selector-contenido {
    display: flex;
}

.ddh-buscador-wrap {
    position: relative;
    margin: 0 0 0.82rem;
}

.ddh-buscador-wrap::before {
    content: "";
    position: absolute;
    left: 0.82rem;
    top: 50%;
    width: 0.72rem;
    height: 0.72rem;
    border: 2px solid #7b8492;
    border-radius: 50%;
    transform: translateY(-58%);
    z-index: 1;
}

.ddh-buscador-wrap::after {
    content: "";
    position: absolute;
    left: 1.48rem;
    top: 50%;
    width: 0.45rem;
    height: 2px;
    background: #7b8492;
    transform: translateY(0.25rem) rotate(45deg);
    transform-origin: left center;
    z-index: 1;
}

.ddh-input-texto,
.ddh-campo-fecha input[type="date"] {
    width: 100%;
    min-height: 2.62rem;
    border: 1px solid #cfd9e5;
    border-radius: 5px;
    background: #ffffff;
    color: #445166;
    font-size: 0.95rem;
    font-weight: 500;
    box-shadow: none;
    box-sizing: border-box;
}

.ddh-input-texto {
    padding: 0.55rem 0.75rem 0.55rem 2.55rem;
}

#ddh-buscador-estacion::-webkit-search-cancel-button {
    cursor: pointer;
}

.ddh-input-texto::placeholder {
    color: #747f91;
    opacity: 1;
}

.ddh-input-texto:focus,
.ddh-campo-fecha input[type="date"]:focus {
    border-color: #72aee0;
    box-shadow: 0 0 0 3px rgba(0, 103, 178, 0.1);
    outline: 0;
}

.ddh-checkbox-list {
    gap: 0.42rem;
    margin-top: 0 !important;
    font-size: 0.92rem;
}

.ddh-checkbox-list-estaciones {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    grid-template-columns: none;
    column-count: 1;
    columns: 1;
    max-height: 15.7rem;
    padding-right: 0.45rem;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-color: #9da6b2 transparent;
    scrollbar-width: thin;
}

#ddh-estacion-lista.ddh-checkbox-list-estaciones {
    display: flex !important;
    flex-direction: column !important;
    flex-wrap: nowrap !important;
    grid-template-columns: none !important;
    column-count: 1 !important;
    columns: 1 !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
}

#ddh-estacion-lista .ddh-check-item {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    width: 100%;
    max-width: 100%;
    break-inside: avoid;
    min-height: 1.2rem;
    color: #2d3036;
    box-sizing: border-box;
}

#ddh-estacion-lista .ddh-check-item input {
    appearance: none;
    -webkit-appearance: none;
    width: 0.95rem;
    height: 0.95rem;
    margin: 0;
    flex: 0 0 0.95rem;
    border: 1px solid #c4ced8;
    border-radius: 3px;
    background: #ffffff;
}

#ddh-estacion-lista .ddh-check-item input:checked {
    border-color: #0067b2;
    background: #0067b2;
    box-shadow: inset 0 0 0 3px #ffffff;
}

.ddh-estado-estaciones,
.ddh-estado-filtro-estaciones {
    padding: 0.35rem 0;
    color: #69778c;
    font-size: 0.86rem;
    line-height: 1.35;
}

.ddh-estado-frecuencias,
.ddh-estado-tipos-dato,
.ddh-estado-parametros {
    padding: 0.2rem 0;
    color: #69778c;
    font-size: 0.82rem;
    line-height: 1.35;
}

.ddh-check-item label {
    display: inline-flex;
    align-items: center;
    color: #2c3037;
    font-size: 0.92rem;
    font-weight: 500;
    line-height: 1.25;
}

.ddh-check-item.ddh-opcion-deshabilitada label,
.ddh-check-item.ddh-opcion-deshabilitada input {
    cursor: not-allowed;
}

.ddh-check-item.ddh-opcion-bloqueada-estacion label,
.ddh-check-item.ddh-opcion-bloqueada-estacion input {
    cursor: not-allowed;
}

.ddh-check-item.ddh-opcion-deshabilitada label {
    color: #8a94a3;
    opacity: 0.62;
}

.ddh-lista-pildoras {
    display: flex;
    flex-flow: row wrap;
    gap: 0.55rem;
}

.ddh-lista-pildoras .ddh-check-item {
    position: relative;
    display: inline-flex;
    width: auto;
}

.ddh-lista-pildoras .ddh-check-item input {
    position: absolute;
    inset: 0;
    opacity: 0;
}

.ddh-lista-pildoras .ddh-check-item label {
    justify-content: center;
    min-width: 4.25rem;
    min-height: 2.1rem;
    padding: 0.42rem 0.92rem;
    border: 1px solid #d4dde8;
    border-radius: 999px;
    background: #ffffff;
    color: #5e6777;
    font-size: 0.83rem;
    font-weight: 600;
    box-sizing: border-box;
}

.ddh-parametro-unidad {
    margin-left: 0.14rem;

    
}

.ddh-parametro-unidad sup {
    font-size: 0.72em;
    line-height: 0;
}

.ddh-lista-pildoras .ddh-check-item input:checked + label {
    border-color: #0067b2;
    background: #0067b2;
    color: #ffffff;
    
}

.ddh-lista-pildoras .ddh-check-item.ddh-opcion-deshabilitada label {
    border-color: #d9e1ea;
    background: #f2f5f8;
    color: #8792a2;
    opacity: 1;
}

.ddh-panel-seleccion {
    width: 95%;
    max-width: none;
    min-height: 0;
    margin: 0;
    padding: 1.55rem 1.45rem 1.42rem;
    gap: 1.28rem;
    background: #ffffff;
    border: 1px solid #dfe8f1;
    border-radius: 12px;
    box-shadow: 0 14px 32px rgba(17, 45, 75, 0.08);
    box-sizing: border-box;
        margin: 0 auto;
    margin-top: 2em;
}

.ddh-panel-cabecera {
    display: flex;
    align-items: center;
    gap: 1.18rem;
}

.ddh-panel-icono {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 4.25rem;
    height: 4.25rem;
    flex: 0 0 4.25rem;
    border-radius: 50%;
    background: #e8f3fd;
}

.ddh-panel-icono img {
    display: block;
    width: 2.2rem;
    height: 2.2rem;
    object-fit: contain;
}

.ddh-panel-cabecera-texto {
    min-width: 0;
}
 
.ddh-panel-titulo-nuevo {
    margin: 0;
    color: #003b73;
    font-size: 1.65rem;
    line-height: 1.15;
    letter-spacing: 0;
}

.ddh-panel-cabecera-texto p {
    margin: 0.48rem 0 0;
    color: #69778c;
    font-size: 0.98rem;
    line-height: 1.35;
}

.ddh-panel-separador {
    height: 1px;
    background: #dbe4ee;
}

.ddh-bloque {
    gap: 0.9rem;
    padding: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.ddh-paso {
    display: flex;
    flex-direction: column;
    gap: 0.88rem;
}

.ddh-paso > .texto-titulo {
    margin: 0;
    color: #0067b2;
    font-size: 1rem;
    line-height: 1.2;
    letter-spacing: 0;
}

.ddh-paso-periodo > .texto-titulo,
.ddh-bloque-descarga > .texto-titulo {
    font-size: 0;
}

.ddh-paso-periodo > .texto-titulo::before,
.ddh-bloque-descarga > .texto-titulo::before {
    color: #0067b2;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.2;
}

.ddh-paso-periodo > .texto-titulo::before {
    content: "2. Periodo de consulta";
}

.ddh-bloque-descarga > .texto-titulo::before {
    content: "3. Formato de descarga";
}

.ddh-filas-fecha {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 3.9rem;
    align-items: end;
    justify-content: stretch;
}

.ddh-campo-fecha {
    width: 100%;
    gap: 0.45rem;
}

.ddh-campo-fecha label {
    color: #14181f;
    font-size: 0.82rem;
    font-weight: 600;
}

.ddh-campo-fecha input[type="date"] {
    padding: 0.5rem 0.85rem;
}

.ddh-aviso-periodo {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    min-height: 3.6rem;
    padding: 0.78rem 1rem;
    border: 1px solid #afd2f0;
    border-radius: 5px;
    background: #f3f8fe;
    color: #005da5;
    font-size: 0.86rem;
    line-height: 1.45;
    box-sizing: border-box;
}

.ddh-aviso-icono {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.55rem;
    height: 1.55rem;
    flex: 0 0 1.55rem;
    border: 0;
    border-radius: 0;
}

.ddh-aviso-icono img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.ddh-zona-senales {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 8.2rem;
    border: 1px dashed #b8d4ec;
    border-radius: 8px;
    background: #ffffff;
    box-sizing: border-box;
}

.ddh-panel-vacio {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.38rem;
    width: 100%;
    min-height: 100%;
    padding: 1rem;
    border: 0;
    background: transparent;
    box-shadow: none;
    color: #566274;
    text-align: center;
    font-size: 0;
}

.ddh-panel-vacio > * {
    display: block;
}

.ddh-panel-vacio strong {
    max-width: 32rem;
    margin: 0;
    color: #4e5d70;
    font-size: 0.95rem;
    line-height: 1.25;
}

.ddh-panel-vacio span:not(.ddh-vacio-icono) {
    max-width: 38rem;
    margin: 0;
    color: #69778c;
    font-size: 0.82rem;
    line-height: 1.35;
}

.ddh-vacio-icono {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    margin: 0 auto;
}

.ddh-vacio-icono img {
    display: block;
    width: 2.65rem;
    height: 2.65rem;
    object-fit: contain;
}

.ddh-lista-senales {
    width: 100%;
    max-height: 16rem;
    gap: 0.75rem;
    padding: 1rem;
    box-sizing: border-box;
}

.ddh-item-senal {
    border: 1px solid #dbe4ee;
    border-radius: 7px;
    background: #f9fcff;
    box-shadow: none;
}

.ddh-item-titulo {
    color: #003b73;
}

.ddh-chip {
    border-color: #cfe1f2;
    background: #ffffff;
    color: #405972;
}

.ddh-bloque-descarga {
    margin-top: 0;
}

.ddh-formatos {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2rem;
}

.ddh-formato-item {
    position: relative;
    display: grid;
    grid-template-columns: auto auto minmax(0, 1fr);
    align-items: center;
    gap: 1rem;
    min-height: 5.55rem;
    padding: 1rem 1.25rem;
    border: 1px solid #d7e0eb;
    border-radius: 6px;
    background: #ffffff;
    color: #405166;
    font-size: 0.95rem;
    box-shadow: none;
    box-sizing: border-box;
}

.ddh-formato-item:has(input:checked) {
    border-color: #0067b2;
    box-shadow: inset 0 0 0 1px rgba(0, 103, 178, 0.22);
}

.ddh-formato-item input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.ddh-radio-visual {
    width: 1.05rem;
    height: 1.05rem;
    border: 1px solid #aebac8;
    border-radius: 50%;
    background: #ffffff;
    box-sizing: border-box;
}

.ddh-formato-item input:checked + .ddh-radio-visual {
    border: 5px solid #0067b2;
}

.ddh-formato-archivo {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.72rem;
    height: 3.18rem;
    border-radius: 4px;
    background: #2e9f59;
    color: #ffffff;
    font-size: 0.78rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0;
    overflow: hidden;
}

.ddh-formato-archivo::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    border-top: 0.68rem solid #c9efd8;
    border-left: 0.68rem solid transparent;
}

.ddh-formato-texto {
    display: flex;
    flex-direction: column;
    gap: 0.28rem;
    min-width: 0;
}

.ddh-formato-texto strong {
    color: #0067b2;
    font-size: 0.95rem;
    line-height: 1.15;
}

.ddh-formato-texto small {
    color: #69778c;
    font-size: 0.78rem;
    line-height: 1.35;
}

.ddh-botones-descarga {
    display: flex;
    justify-content: center;
    margin-top: 0.25rem;
}

#ddh-btn-descargar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.62rem;
    width: 17.6rem;
    max-width: 100%;
    min-height: 3rem;
    padding: 0.55rem 1rem;
    border-radius: 6px;
    background: #0067b2;
    color: #ffffff;
    font-size: 0.98rem;
    font-weight: 800;
    line-height: 1;
}

#ddh-btn-descargar:hover {
    background: #005c9f;
}

#ddh-btn-descargar:disabled {
    background: #0067b2;
    opacity: 0.82;
    cursor: not-allowed;
}

.ddh-mensaje-estado {
    border-radius: 6px;
}

@media (max-width: 1000px) {
    .ddh-layout {
        max-width: none;
        gap: 1.25rem;
    }

    .ddh-col-izquierda {
        flex: 1 1 auto;
    }

    .ddh-formulario {
        max-width: none;
    }
}

@media (max-width: 760px) {
    .ddh-panel-seleccion {
        padding: 1.15rem;
    }

    .ddh-panel-cabecera {
        align-items: flex-start;
    }

    .ddh-panel-icono {
        width: 3.35rem;
        height: 3.35rem;
        flex-basis: 3.35rem;
    }

    .ddh-panel-titulo-nuevo {
        font-size: 1.35rem;
    }

    .ddh-filas-fecha,
    .ddh-formatos {
        grid-template-columns: 1fr;
        gap: 0.9rem;
    }

    .ddh-formato-item {
        gap: 0.75rem;
        padding: 0.9rem;
    }
}

/* Compactacion general del plugin de descarga. */
.ddh-layout {
    max-width: 84rem;
    gap: 1rem;
}

.ddh-col-izquierda {
    flex-basis: 21rem;
}

.ddh-formulario {
    max-width: 21rem;
    font-size: 0.92rem;
}

.ddh-filtros-cabecera {
    min-height: 3rem;
    gap: 0.65rem;
    padding: 0.78rem 1rem;
}

.ddh-filtros-cabecera .ddh-titulo {
    font-size: 0.93rem;
}

.ddh-icono-filtro {
    width: 1rem;
    height: 1rem;
    flex-basis: 1rem;
}

.ddh-selector-toggle {
    padding: 0.82rem 1rem 0.58rem;
}

.ddh-selector-toggle .texto-titulo {
    font-size: 0.88rem;
}

.ddh-selector-contenido {
    padding: 0 1rem 0.92rem;
}

.ddh-formulario > .ddh-botones {
    padding: 0 1rem 0.95rem;
    margin-top: 0.55rem;
}

.ddh-input-texto,
.ddh-campo-fecha input[type="date"] {
    min-height: 2.28rem;
    font-size: 0.86rem;
}

.ddh-input-texto {
    padding: 0.45rem 0.68rem 0.45rem 2.35rem;
}

.ddh-buscador-wrap {
    margin-bottom: 0.68rem;
}

.ddh-checkbox-list {
    gap: 0.34rem;
    font-size: 0.86rem;
}

.ddh-checkbox-list-estaciones {
    max-height: 13.8rem;
}

#ddh-estacion-lista .ddh-check-item {
    gap: 0.45rem;
    min-height: 1.05rem;
}

#ddh-estacion-lista .ddh-check-item input {
    width: 0.82rem;
    height: 0.82rem;
    flex-basis: 0.82rem;
}

.ddh-check-item label {
    font-size: 0.86rem;
}

.ddh-lista-pildoras {
    gap: 0.45rem;
}

.ddh-lista-pildoras .ddh-check-item label {
    min-width: 3.8rem;
    min-height: 1.88rem;
    padding: 0.34rem 0.78rem;
    font-size: 0.78rem;
}

#ddh-btn-anadir-senal {
    width: auto;
    min-width: 8rem;
    padding: 0.42rem 0.95rem;
    border-radius: 6px;
    font-size: 0.92rem;
}

.ddh-panel-seleccion {
    padding: 1.25rem 1.25rem 1.15rem;
    gap: 1rem;
    border-radius: 10px;
}

.ddh-panel-cabecera {
    gap: 0.95rem;
}

.ddh-panel-icono {
    width: 3.35rem;
    height: 3.35rem;
    flex-basis: 3.35rem;
}

.ddh-panel-icono img {
    width: 1.78rem;
    height: 1.78rem;
}

.ddh-panel-titulo-nuevo {
    font-size: 1.36rem;
}

.ddh-panel-cabecera-texto p {
    margin-top: 0.32rem;
    font-size: 0.88rem;
}

.ddh-paso {
    gap: 0.68rem;
}

.ddh-paso > .texto-titulo,
.ddh-paso-periodo > .texto-titulo::before,
.ddh-bloque-descarga > .texto-titulo::before {
    font-size: 0.92rem;
}

.ddh-paso-periodo > .texto-titulo,
.ddh-bloque-descarga > .texto-titulo {
    font-size: 0;
}

.ddh-filas-fecha {
    gap: 2.5rem;
}

.ddh-campo-fecha {
    gap: 0.32rem;
}

.ddh-campo-fecha label {
    font-size: 0.76rem;
}

.ddh-campo-fecha input[type="date"] {
    padding: 0.4rem 0.72rem;
}

.ddh-aviso-periodo {
    min-height: 3rem;
    gap: 0.65rem;
    padding: 0.62rem 0.82rem;
    font-size: 0.78rem;
}

.ddh-aviso-icono {
    width: 1.32rem;
    height: 1.32rem;
    flex-basis: 1.32rem;
    font-size: 0.86rem;
}

.ddh-zona-senales {
    flex-direction: column;
    min-height: 6.6rem;
}

.ddh-panel-vacio {
    flex: 1 1 auto;
    margin: 0 auto;
    gap: 0.26rem;
    padding: 0.75rem;
}

.ddh-vacio-icono {
    width: 2.35rem;
    height: 2.35rem;
}

.ddh-vacio-icono img {
    width: 2.05rem;
    height: 2.05rem;
}

.ddh-panel-vacio strong {
    font-size: 0.86rem;
}

.ddh-panel-vacio span:not(.ddh-vacio-icono) {
    font-size: 0.76rem;
}

.ddh-lista-senales {
    max-height: 13rem;
    gap: 0.58rem;
    padding: 0.75rem;
}

.ddh-lista-senales:empty {
    display: none !important;
    width: 0;
    height: 0;
    padding: 0;
}

.ddh-item-senal {
    padding: 0.65rem 0.75rem;
}

.ddh-formatos {
    gap: 1.25rem;
}

.ddh-formato-item {
    min-height: 4.45rem;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    font-size: 0.86rem;
}

.ddh-radio-visual {
    width: 0.9rem;
    height: 0.9rem;
}



.ddh-formato-archivo {
    width: 2.25rem;
    height: 2.65rem;
    font-size: 0.68rem;
}

.ddh-formato-archivo::before {
    border-top-width: 0.56rem;
    border-left-width: 0.56rem;
}

.ddh-formato-texto {
    gap: 0.18rem;
}

.ddh-formato-texto strong {
    font-size: 0.86rem;
}

.ddh-formato-texto small {
    font-size: 0.72rem;
}

#ddh-btn-descargar {
    width: 12rem;
    min-height: 2.45rem;
    padding: 0.45rem 0.9rem;
    gap: 0.5rem;
    font-family: "Jost", sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
}

#ddh-btn-anadir-senal {
    font-family: "Jost", sans-serif;
    font-size: 0.92rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
}

@media (max-width: 1000px) {
    .ddh-layout {
        max-width: none;
    }

	.ddh-col-izquierda {
	    flex-basis: auto;
	}

	.ddh-formulario {
	    max-width: none;
	}
}

@media (max-width: 760px) {
    .ddh-panel-seleccion {
        padding: 1rem;
    }

    .ddh-filas-fecha,
    .ddh-formatos {
        gap: 0.78rem;
    }
}

/* Mensajes de estado de descarga: bloque de resultado sobrio. */
.ddh-mensaje-estado {
    --ddh-estado-azul: #0067b2;
    --ddh-estado-texto: #334155;
    --ddh-estado-fondo: #f7f9fb;
    --ddh-estado-borde: #d8e1ea;
    --ddh-estado-chip: #eef3f7;
    display: none;
    width: 100%;
    padding: 0.92rem 1rem;
    border: 1px solid var(--ddh-estado-borde);
    border-radius: 6px;
    background: var(--ddh-estado-fondo);
    color: var(--ddh-estado-texto);
    font-size: 0.9rem;
    line-height: 1.38;
    box-shadow: none;
    box-sizing: border-box;
}

.ddh-mensaje-estado.info,
.ddh-mensaje-estado.ok,
.ddh-mensaje-estado.error {
    display: block;
}

.ddh-mensaje-estado.info {
    --ddh-estado-texto: #2f5f83;
    --ddh-estado-fondo: #f6f9fb;
    --ddh-estado-borde: #d7e4ec;
    --ddh-estado-chip: #eaf2f7;
}

.ddh-mensaje-estado.ok {
    --ddh-estado-texto: #2f5f83;
    --ddh-estado-fondo: #f6f9fb;
    --ddh-estado-borde: #d7e4ec;
    --ddh-estado-chip: #eaf2f7;
    background: var(--ddh-estado-fondo);
    background-color: var(--ddh-estado-fondo);
    color: var(--ddh-estado-texto);
}

.ddh-mensaje-estado.error {
    --ddh-estado-texto: #7b454d;
    --ddh-estado-fondo: #fbf7f7;
    --ddh-estado-borde: #ead8db;
    --ddh-estado-chip: #f7edef;
}

.ddh-mensaje-progreso-cabecera {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.95rem;
}

.ddh-mensaje-progreso-texto {
    display: block;
    min-width: 0;
    color: #26313d;
    font-size: 0.96rem;
    font-weight: 750;
    line-height: 1.32;
}

.ddh-mensaje-progreso-texto::before {
    content: "Estado de descarga";
    display: block;
    margin-bottom: 0.28rem;
    color: #0067b2;
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 0;
    line-height: 1.2;
    text-transform: none;
}

.ddh-mensaje-progreso-valor {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 4.25rem;
    min-height: 2.15rem;
    padding: 0.25rem 0.75rem;
    border: 1px solid var(--ddh-estado-borde);
    border-radius: 6px;
    background: var(--ddh-estado-chip);
    color: var(--ddh-estado-texto);
    font-size: 0.82rem;
    font-weight: 850;
    line-height: 1;
    text-align: center;
}

.ddh-mensaje-progreso-barra {
    display: none;
}

.ddh-mensaje-progreso-relleno,
.ddh-mensaje-estado.ok .ddh-mensaje-progreso-relleno,
.ddh-mensaje-estado.error .ddh-mensaje-progreso-relleno {
    display: block;
    background: var(--ddh-estado-texto);
}

.ddh-resumen-descarga {
    display: grid;
    gap: 0;
    margin-top: 0.95rem;
    border: 1px solid var(--ddh-estado-borde);
    border-radius: 6px;
    background: #ffffff;
    overflow: hidden;
}

.ddh-resumen-grupo {
    display: grid;
    gap: 0.45rem;
    padding: 0.78rem 0.9rem;
    border-bottom: 1px solid #e6edf3;
}

.ddh-resumen-grupo:last-child {
    border-bottom: 0;
}

.ddh-resumen-titulo {
    color: var(--ddh-estado-azul);
    font-size: 0.78rem;
    font-weight: 850;
    line-height: 1.2;
}

.ddh-resumen-lista {
    display: grid;
    gap: 0.28rem;
    margin: 0;
    padding: 0;
    color: #5d6976;
    list-style: none;
}

.ddh-resumen-lista li {
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.ddh-resumen-item {
    position: relative;
    min-height: 1.25rem;
    padding-left: 1.65rem;
}

.ddh-resumen-item::before {
    content: "";
    position: absolute;
    top: 0.05rem;
    left: 0;
    width: 1.05rem;
    height: 1.05rem;
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
}

.ddh-resumen-grupo-descargadas .ddh-resumen-item::before {
    background-image: url("images/cheque.svg");
}

.ddh-resumen-grupo-sin-datos .ddh-resumen-item::before {
    background-image: url("images/borrar.svg");
}

.ddh-resumen-grupo-error .ddh-resumen-item::after {
    content: "!";
    position: absolute;
    top: 0.08rem;
    left: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1rem;
    height: 1rem;
    color: var(--ddh-estado-azul);
    font-size: 0.72rem;
    font-weight: 900;
    line-height: 1;
}

.ddh-resumen-extra {
    color: #6b7785;
    font-style: normal;
    font-weight: 700;
}

@media (max-width: 520px) {
    .ddh-mensaje-estado {
        padding: 0.82rem 0.85rem;
        font-size: 0.85rem;
    }

    .ddh-mensaje-progreso-cabecera {
        grid-template-columns: minmax(0, 1fr);
        gap: 0.62rem;
    }

    .ddh-mensaje-progreso-valor {
        justify-self: flex-start;
        min-height: 1.9rem;
    }
}
