.portal-notices {
    font-family: "Lato", sans-serif;
    margin: 0 0 1.5rem 0;
}

#content>.toolbar+.portal-notices {
    margin: 0.35rem 0 1rem 0;
}

.portal-notice {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: #fff;
    border: 3px solid #000;
    border-radius: 9999px;
    color: #000;
    padding: 1rem 1.15rem;
    margin-bottom: 0.75rem;
    box-sizing: border-box;
}

.portal-notice:last-child {
    margin-bottom: 0;
}

.portal-notice-icon {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3.25rem;
    height: 3.25rem;
    margin: 0;
    align-self: center;
    box-sizing: border-box;
}

/* Aviso: rombo amarillo con exclamación (prototipo PODAM-182) */
.portal-notice-icon--notice {
    background: #f5c518;
    border: 3px solid #000;
    border-radius: 0.25rem;
    transform: rotate(45deg);
}

.portal-notice-icon--notice .portal-notice-icon-mark {
    transform: rotate(-45deg);
    color: #000;
    font-weight: 900;
    font-size: 1.75rem;
    line-height: 1;
    font-family: "Lato", Arial, sans-serif;
}

/* Noticia: equivalente en cápsula negra; icono circular azul con periódico */
.portal-notice-icon--news {
    background: #1d4ed8;
    border: 3px solid #000;
    border-radius: 50%;
    color: #fff;
    font-size: 1.55rem;
}

.portal-notice-content {
    flex: 1 1 auto;
    min-width: 0;
}

.portal-notice-type-label {
    font-weight: 900;
    font-size: 1.5rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    margin-bottom: 0.25rem;
    color: #000;
    line-height: 1.2;
}

.portal-notice-title {
    font-weight: 700;
    font-size: 1.4rem;
    line-height: 1.35;
    margin-bottom: 0.3rem;
    color: #000;
}

.portal-notice-body {
    color: #000;
    font-size: 1.2rem;
    line-height: 1.5;
}

.portal-notice-body p {
    margin: 0;
}

.portal-notice-body a {
    color: var(--link-color, #0000ff);
    text-decoration: underline;
}

.portal-notice-dismiss {
    flex-shrink: 0;
    margin-left: auto;
    background: transparent;
    border: 0;
    color: var(--gray-text, #767676);
    font-size: 1.4rem;
    line-height: 1;
    padding: 0.15rem 0.25rem;
    cursor: pointer;
}

.portal-notice-dismiss:hover,
.portal-notice-dismiss:focus {
    color: #000;
}

@media (max-width: 767.98px) {
    .portal-notice {
        border-radius: 1.5rem;
        align-items: center;
    }

    .portal-notice-icon {
        width: 2.75rem;
        height: 2.75rem;
    }

    .portal-notice-icon--notice .portal-notice-icon-mark {
        font-size: 1.45rem;
    }

    .portal-notice-icon--news {
        font-size: 1.3rem;
    }

    .portal-notice-type-label {
        font-size: 1.1rem;
    }
}

/* Administración /ckan-admin/notices — paridad con listados PODAM */
.listado-container.notices-admin-page {
    width: 75%;
    max-width: none;
    margin: 30px auto;
    padding: 2em;
    box-sizing: border-box;
}

.notices-admin-intro {
    color: #555;
    margin-bottom: 1.5rem;
}

.notices-filters-title {
    margin-bottom: 20px;
    color: #212529;
    font-size: 1.8rem;
    font-weight: 600;
}

.listado-container.notices-admin-page table {
    table-layout: fixed;
    width: 100%;
}

.listado-container.notices-admin-page table th,
.listado-container.notices-admin-page table td {
    width: auto;
    max-width: none;
    text-align: left;
    vertical-align: middle;
    white-space: normal;
    overflow: visible;
    text-overflow: unset;
}

.listado-container.notices-admin-page table th:nth-child(1),
.listado-container.notices-admin-page table td:nth-child(1) {
    width: 5%;
}

/* Columna Acciones: ancho fijo del botón + margen (como xloader) */
.listado-container.notices-admin-page table th:nth-child(8),
.listado-container.notices-admin-page table td:nth-child(8) {
    width: 8rem !important;
    min-width: 8rem !important;
    max-width: 8rem !important;
    white-space: nowrap !important;
    text-align: center;
    vertical-align: middle;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
    overflow: visible !important;
    text-overflow: clip !important;
}

.listado-container.notices-admin-page table td:nth-child(8) .dropdown {
    position: relative;
    display: inline-block;
    vertical-align: middle;
}

.notices-title-cell {
    font-weight: 600;
}

.notices-dataset-link,
.notices-dataset-id {
    display: inline-block;
    max-width: 100%;
    margin-top: 0.2rem;
    font-weight: 600;
    color: #1d4ed8;
    text-decoration: underline;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
}

.notices-dataset-id {
    font-weight: 400;
    color: inherit;
    text-decoration: none;
}

.notices-dataset-link:hover,
.notices-dataset-link:focus {
    color: #1e40af;
}

.notices-type-cell {
    padding: 0.45rem 0.5rem;
    vertical-align: middle;
}

.notices-type-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 2.25rem;
    box-sizing: border-box;
    margin: 0;
    padding: 0.4rem 0.6rem;
    border-radius: 4px;
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
    background: #f4f4f4;
    border-left: 4px solid #d97706;
}

.notices-type-notice {
    border-left-color: #d97706;
}

.notices-type-news {
    border-left-color: #1d4ed8;
}

.notices-form-row {
    margin-top: 1rem;
}

.notices-form-wide {
    flex: 1 1 100%;
    min-width: 100%;
}

.notices-form-check {
    display: flex;
    align-items: flex-end;
    min-height: 58px;
}

.notices-checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: #495057;
    margin: 0;
}

.notices-form-actions {
    margin-top: 1.25rem;
}

.notices-editor-help {
    margin: 0.5rem 0 0;
    font-size: 0.875rem;
    color: #6c757d;
}

.notices-form-wide .ck-editor {
    width: 100%;
}

.notices-form-wide .ck-editor__editable {
    min-height: 12rem;
}

.portal-notice-body h3,
.portal-notice-body h4 {
    margin: 0 0 0.35rem;
    font-size: 1.05em;
    font-weight: 700;
}

.portal-notice-body ul,
.portal-notice-body ol {
    margin: 0.25rem 0 0.5rem 1.25rem;
    padding: 0;
}

.notices-admin-page .dropdown-item {
    display: block;
    width: 100%;
    text-align: left;
    background: none;
    border: 0;
    padding: 0.4rem 1rem;
}

.notices-admin-page .dropdown-menu form {
    margin: 0;
}

.notices-admin-page .filter-buttons .btn {
    white-space: nowrap;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 500;
    color: #212529;
    background-color: orange;
    transition: all 0.3s ease;
    padding: 8px 16px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.notices-admin-page .filter-buttons .btn i {
    font-size: 1rem;
    margin-right: 5px;
    color: #212529;
}

.notices-admin-page .filter-buttons .btn:hover {
    background-color: #e69500;
    color: #212529;
    text-decoration: none;
}

.notices-admin-page .btn-orange {
    background-color: orange;
    color: #212529;
    border: none;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 0.85rem;
    font-weight: 500;
    white-space: nowrap;
}

.notices-admin-page .btn-orange:hover,
.notices-admin-page .btn-orange:focus,
.notices-admin-page .btn-orange.show {
    background-color: #e69500;
    color: #212529;
}

.notices-admin-page .dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
}

.notices-admin-page .dropdown-item i {
    width: 16px;
    text-align: center;
}