.io-noticias {
    --io-red: #b51d25;
    --io-red-dark: #8f1219;
    --io-text: #151515;
    --io-muted: #666666;
    --io-border: #e7e7e7;
    --io-bg: #ffffff;
    --io-soft: #f7f7f7;
    color: var(--io-text);
    font-family: inherit;
}

.io-noticias *,
.io-noticias *::before,
.io-noticias *::after {
    box-sizing: border-box;
}

.io-card {
    background: var(--io-bg);
    border: 1px solid var(--io-border);
    border-radius: 18px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.06);
    overflow: hidden;
}

.io-noticias-form-wrap {
    max-width: 820px;
    margin: 24px auto;
}

.io-login-card,
.io-form-card,
.io-admin-help .io-card,
.io-empty {
    padding: 28px;
}

.io-form-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 22px;
}

.io-kicker {
    margin: 0 0 6px;
    color: var(--io-red);
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.io-noticias h2,
.io-noticias h3,
.io-noticias p {
    margin-top: 0;
}

.io-noticias h2 {
    margin-bottom: 8px;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.1;
}

.io-noticias h3 {
    margin-bottom: 10px;
    font-size: clamp(20px, 2.2vw, 26px);
    line-height: 1.2;
}

.io-noticias p,
.io-noticias label,
.io-noticias input,
.io-noticias textarea,
.io-noticias button,
.io-noticias a {
    font-size: 18px;
}

.io-field {
    margin-bottom: 22px;
}

.io-field label,
.io-login-card label {
    display: block;
    margin-bottom: 8px;
    font-weight: 800;
}

.io-field input[type="text"],
.io-field input[type="file"],
.io-field textarea,
.io-login-card input[type="text"],
.io-login-card input[type="password"] {
    width: 100%;
    min-height: 58px;
    padding: 14px 16px;
    color: var(--io-text);
    background: #fff;
    border: 2px solid #d9d9d9;
    border-radius: 14px;
    outline: none;
}

.io-field textarea {
    min-height: 220px;
    resize: vertical;
}

.io-field input:focus,
.io-field textarea:focus,
.io-login-card input:focus {
    border-color: var(--io-red);
    box-shadow: 0 0 0 4px rgba(181, 29, 37, 0.12);
}

.io-field small {
    display: block;
    margin-top: 8px;
    color: var(--io-muted);
    font-size: 15px;
}

.io-main-button,
.io-login-card .button,
.io-read-more,
.io-share a,
.io-share button,
.io-logout {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 12px 18px;
    border: 0;
    border-radius: 999px;
    font-weight: 800;
    text-decoration: none !important;
    cursor: pointer;
    transition: transform 0.15s ease, opacity 0.15s ease;
}

.io-main-button,
.io-login-card .button,
.io-read-more {
    background: var(--io-red);
    color: #fff !important;
}

.io-main-button {
    width: 100%;
    min-height: 66px;
    font-size: 22px !important;
}

.io-main-button:hover,
.io-login-card .button:hover,
.io-read-more:hover,
.io-share a:hover,
.io-share button:hover,
.io-logout:hover {
    transform: translateY(-1px);
    opacity: 0.92;
}

.io-logout,
.io-share a,
.io-share button {
    background: var(--io-soft);
    color: var(--io-text) !important;
}

.io-login-card .login-remember {
    display: flex;
    align-items: center;
    gap: 10px;
}

.io-login-card input[type="checkbox"] {
    width: 22px;
    height: 22px;
}

.io-alert {
    margin-bottom: 18px;
    padding: 18px 20px;
    border-radius: 16px;
    font-size: 18px;
}

.io-alert-success {
    background: #eef9f0;
    border: 1px solid #b9e4c0;
    color: #174d24;
}

.io-alert-error {
    background: #fff0f1;
    border: 1px solid #f1c5c8;
    color: #7b1218;
}

.io-panel-header {
    margin-bottom: 22px;
    text-align: left;
}

.io-news-grid {
    display: grid;
    grid-template-columns: repeat(var(--io-columns, 3), minmax(0, 1fr));
    gap: 22px;
}

.io-news-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.io-news-image {
    display: block;
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 10;
    background: #161616;
    color: #fff !important;
    text-decoration: none !important;
    overflow: hidden;
}

.io-news-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.io-image-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    background: linear-gradient(135deg, #161616, #b51d25);
    color: #fff;
    font-weight: 900;
    text-align: center;
}

.io-news-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 20px;
}

.io-news-body time {
    display: inline-block;
    margin-bottom: 10px;
    color: var(--io-muted);
    font-size: 15px;
    font-weight: 700;
}

.io-news-body h3 a {
    color: var(--io-text) !important;
    text-decoration: none !important;
}

.io-news-body h3 a:hover {
    color: var(--io-red) !important;
}

.io-news-body p {
    color: #363636;
    line-height: 1.55;
}

.io-reference {
    margin-top: auto;
    padding: 12px 14px;
    background: var(--io-soft);
    border-radius: 12px;
    color: #333;
    font-size: 15px;
    line-height: 1.45;
}

.io-reference a {
    color: var(--io-red) !important;
    font-size: inherit;
    font-weight: 800;
}

.io-card-footer {
    margin-top: 16px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.io-share {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.io-share a,
.io-share button {
    min-height: 40px;
    padding: 9px 13px;
    border: 1px solid var(--io-border);
    font-size: 14px !important;
}

.io-single-extra {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--io-border);
}

.io-single-reference {
    margin-bottom: 16px;
}

.io-admin-help .io-card {
    max-width: 900px;
    margin: 16px 0;
}

.io-admin-help code {
    display: inline-block;
    padding: 4px 8px;
    background: #f1f1f1;
    border-radius: 6px;
}

@media (max-width: 1024px) {
    .io-news-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .io-news-grid {
        grid-template-columns: 1fr;
    }

    .io-login-card,
    .io-form-card,
    .io-admin-help .io-card,
    .io-empty {
        padding: 20px;
    }

    .io-form-head {
        flex-direction: column;
    }

    .io-noticias p,
    .io-noticias label,
    .io-noticias input,
    .io-noticias textarea,
    .io-noticias button,
    .io-noticias a {
        font-size: 17px;
    }
}

.io-head-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
}

.io-manage-card {
    margin-top: 24px;
    padding: 28px;
}

.io-manage-head {
    margin-bottom: 16px;
}

.io-manage-list {
    display: grid;
    gap: 14px;
}

.io-manage-item {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 16px;
    align-items: center;
    padding: 14px;
    border: 1px solid var(--io-border);
    border-radius: 16px;
    background: #fff;
}

.io-manage-thumb {
    width: 92px;
    height: 74px;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(135deg, #161616, #b51d25);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.io-manage-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.io-manage-info h3 {
    margin: 0 0 4px;
    font-size: 22px;
}

.io-manage-info p {
    margin: 0 0 12px;
    color: var(--io-muted);
    font-size: 15px;
}

.io-manage-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.io-delete-form {
    margin: 0;
}

.io-mini-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 16px;
    border: 1px solid var(--io-border);
    border-radius: 999px;
    background: var(--io-soft);
    color: var(--io-text) !important;
    font-size: 15px !important;
    font-weight: 800;
    text-decoration: none !important;
    cursor: pointer;
}

.io-danger-button {
    background: #fff0f1;
    border-color: #f1c5c8;
    color: #8f1219 !important;
}

.io-empty-compact {
    padding: 18px 0 0;
    box-shadow: none;
    border: 0;
}

.io-latest-panel {
    margin-top: 34px;
    padding-top: 28px;
    border-top: 1px solid var(--io-border);
}

.single-io_noticia #secondary,
.single-io_noticia .secondary,
.io-noticia-single-full #secondary,
.io-noticia-single-full .widget-area.secondary,
.io-noticia-single-full aside.sidebar-main,
.io-noticia-single-full .sidebar-main {
    display: none !important;
}

.single-io_noticia #primary,
.io-noticia-single-full #primary,
.io-noticia-single-full .content-area,
.io-noticia-single-full .site-main {
    width: 100% !important;
    max-width: 1200px;
}

@media (max-width: 720px) {
    .io-manage-card {
        padding: 20px;
    }

    .io-manage-item {
        grid-template-columns: 1fr;
    }

    .io-manage-thumb {
        width: 100%;
        height: 150px;
    }

    .io-head-actions,
    .io-manage-actions {
        justify-content: flex-start;
    }

    .io-mini-button,
    .io-delete-form {
        width: 100%;
    }

    .io-mini-button {
        min-height: 48px;
    }
}

/* Versión 1.2: panel lateral interno para noticias individuales */
.io-single-layout {
    display: grid;
    grid-template-columns: minmax(240px, 310px) minmax(0, 1fr);
    gap: 34px;
    align-items: flex-start;
    width: 100%;
}

.io-single-sidebar {
    position: sticky;
    top: 110px;
    padding: 22px;
    background: #fff;
    border: 1px solid var(--io-border);
    border-radius: 18px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.06);
}

.io-single-sidebar h2 {
    margin: 0 0 18px;
    font-size: clamp(24px, 2.3vw, 34px);
    color: var(--io-red);
    line-height: 1;
}

.io-latest-list {
    display: grid;
    gap: 12px;
}

.io-latest-item {
    display: grid;
    grid-template-columns: 68px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 10px;
    color: var(--io-text) !important;
    background: #fff;
    border: 1px solid var(--io-border);
    border-radius: 14px;
    text-decoration: none !important;
}

.io-latest-item:hover,
.io-latest-item.is-current {
    border-color: rgba(181, 29, 37, 0.35);
    background: #fff7f7;
}

.io-latest-thumb {
    width: 68px;
    height: 58px;
    border-radius: 10px;
    overflow: hidden;
    background: linear-gradient(135deg, #161616, #b51d25);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 900;
}

.io-latest-thumb img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.io-latest-text {
    display: block;
    min-width: 0;
}

.io-latest-date {
    display: block;
    margin-bottom: 3px;
    color: var(--io-muted);
    font-size: 13px;
    font-weight: 700;
}

.io-latest-text strong {
    display: block;
    color: var(--io-text);
    font-size: 15px;
    line-height: 1.25;
}

.io-latest-text em {
    display: inline-block;
    margin-top: 6px;
    padding: 3px 7px;
    color: #fff;
    background: var(--io-red);
    border-radius: 999px;
    font-size: 12px;
    font-style: normal;
    font-weight: 800;
}

.io-sidebar-empty {
    margin: 0;
    color: var(--io-muted);
    font-size: 16px;
}

.io-single-main {
    min-width: 0;
}

.io-single-content {
    min-width: 0;
}

@media (max-width: 980px) {
    .io-single-layout {
        grid-template-columns: 1fr;
    }

    .io-single-sidebar {
        position: static;
        order: 2;
    }

    .io-single-main {
        order: 1;
    }
}

/* Versión 1.3: autor/medio, carga de imagen y prevención de doble publicación */
.io-main-button:disabled,
.io-main-button.is-loading {
    opacity: 0.68;
    cursor: wait;
    transform: none !important;
}

.io-news-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 10px;
    align-items: center;
    margin-bottom: 10px;
    color: var(--io-muted);
    font-size: 15px;
    font-weight: 700;
}

.io-news-meta time,
.io-news-meta span {
    margin: 0;
    font-size: inherit;
    font-weight: inherit;
}

.io-news-meta span {
    color: var(--io-red);
}

.io-single-source {
    margin-bottom: 18px;
    padding: 13px 16px;
    background: #fff7f7;
    border: 1px solid rgba(181, 29, 37, 0.18);
    border-radius: 14px;
    color: var(--io-text);
    font-size: 17px;
    line-height: 1.45;
}

.io-single-source strong {
    color: var(--io-red);
}


/* Versión 1.4: interfaz mejorada, ancho completo y portada visible */
.io-noticias-form-wrap,
.io-news-panel {
    max-width: 1440px;
    margin: 24px auto;
}

.io-noticias.io-news-panel {
    width: 100%;
}

.io-news-grid {
    gap: 26px;
}

.io-news-card {
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.io-news-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 34px rgba(0, 0, 0, 0.09);
}

.io-news-body {
    padding: 22px;
}

.io-news-body h3 {
    margin-bottom: 10px;
}

.io-news-body h3 a {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.io-news-body > p {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 6.2em;
}

.io-news-image {
    aspect-ratio: 16 / 9;
}

.io-single-layout {
    grid-template-columns: minmax(270px, 340px) minmax(0, 1fr);
    gap: 32px;
    width: 100%;
    max-width: 100%;
}

.io-single-main {
    overflow: hidden;
}

.io-single-main-inner {
    padding: 26px 30px 30px;
}

.io-single-hero {
    width: 100%;
    background: #101010;
}

.io-single-hero img,
.io-single-hero .io-single-hero-image {
    display: block;
    width: 100%;
    height: auto;
    max-height: 560px;
    object-fit: cover;
}

.io-single-head-meta {
    margin-bottom: 14px;
    color: var(--io-muted);
    font-size: 15px;
    font-weight: 700;
}

.io-single-content {
    font-size: 19px;
    line-height: 1.72;
}

.io-single-content p:last-child {
    margin-bottom: 0;
}

.io-single-extra {
    margin-top: 24px;
}

.io-single-sidebar {
    top: 32px;
}

.io-latest-item {
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 14px;
    align-items: start;
    padding: 12px;
}

.io-latest-thumb {
    width: 88px;
    height: 72px;
}

.io-latest-text strong {
    font-size: 16px;
}

.single-io_noticia .site-content .ast-container,
.single-io_noticia .ast-container,
.io-noticia-single-full .site-content .ast-container,
.io-noticia-single-full .ast-container,
.io-noticias-front-page .site-content .ast-container,
.io-noticias-front-page .ast-container {
    width: 100% !important;
    max-width: 1440px !important;
    padding-left: 20px !important;
    padding-right: 20px !important;
}

.io-noticias-front-page #secondary,
.io-noticias-front-page .secondary,
.io-noticias-front-page .widget-area.secondary,
.io-noticias-front-page aside.sidebar-main,
.io-noticias-front-page .sidebar-main {
    display: none !important;
}

.io-noticias-front-page #primary,
.io-noticias-front-page .content-area,
.io-noticias-front-page .site-main {
    width: 100% !important;
    max-width: 100% !important;
}

@media (max-width: 1100px) {
    .io-single-layout {
        grid-template-columns: 300px minmax(0, 1fr);
        gap: 24px;
    }
}

@media (max-width: 980px) {
    .io-single-main-inner {
        padding: 22px;
    }
}

@media (max-width: 720px) {
    .single-io_noticia .site-content .ast-container,
    .single-io_noticia .ast-container,
    .io-noticia-single-full .site-content .ast-container,
    .io-noticia-single-full .ast-container,
    .io-noticias-front-page .site-content .ast-container,
    .io-noticias-front-page .ast-container {
        padding-left: 12px !important;
        padding-right: 12px !important;
    }

    .io-single-main-inner {
        padding: 18px;
    }

    .io-single-hero img,
    .io-single-hero .io-single-hero-image {
        max-height: 320px;
    }

    .io-single-content {
        font-size: 18px;
        line-height: 1.6;
    }

    .io-news-body > p {
        min-height: 0;
    }
}


/* Versión 1.5: evitar compartidos duplicados y mejorar placeholder sin imagen */
.io-image-placeholder {
    font-size: 26px;
    line-height: 1.18;
    letter-spacing: -0.02em;
}

.io-single-hero-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 340px;
    padding: 34px;
    background: linear-gradient(135deg, #161616, #b51d25);
    color: #fff;
    text-align: center;
}

.io-single-hero-placeholder span {
    display: -webkit-box;
    max-width: 900px;
    font-size: clamp(30px, 4vw, 54px);
    line-height: 1.08;
    font-weight: 900;
    letter-spacing: -0.03em;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}


@media (max-width: 720px) {
    .io-image-placeholder {
        font-size: 22px;
    }

    .io-single-hero-placeholder {
        min-height: 230px;
        padding: 22px;
    }
}


/* Versión 1.6: estabilidad de vista individual */
.io-single-main {
    display: block;
}

.io-single-extra .io-reference {
    margin-bottom: 0;
}
