/* news.css — /noticias (listado) y /noticias/{slug} (artículo). Paneles claros como /faq y las
   páginas legales; las tarjetas siguen la paleta de las tarjetas de los juegos. */

/* Botón naranja (como «Jugar») y enlace de volver */
.db-news-btn {
    display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 5px; background: #f58b28;
    color: #152e4e; font-weight: 900; font-size: 14px; text-decoration: none; box-shadow: 0 2px 0 #823d19;
}
.db-news-btn:hover { background: #ffa047; color: #152e4e; }
.db-news-btn:focus-visible, .db-news-card-link:focus-visible, .db-news-back:focus-visible,
.db-news-pagination a:focus-visible, .db-news-breadcrumb a:focus-visible { outline: 3px solid #ffce59; outline-offset: 3px; }

/* Sin noticias / no encontrada */
.db-news-empty {
    max-width: 620px; margin: 0 auto; padding: 30px 30px 32px; text-align: center; color: #4d5b68;
    border: 2px solid #233f4b; border-top: 4px solid var(--db-orange); border-radius: 14px; background: var(--db-surface); box-shadow: var(--db-shadow);
}
.db-news-empty-emblem { width: 120px; height: auto; margin-bottom: 6px; }
.db-news-empty :is(h1, h2) { margin: 0 0 10px; color: #173b64; font-size: clamp(26px, 4vw, 32px); }
.db-news-empty p { margin: 0 auto 20px; max-width: 460px; font-size: 14px; line-height: 1.6; }

/* 404 (public_html/404.php): mismo panel, con el código grande y dos salidas */
.db-not-found .db-not-found-code { margin: 0 auto; color: var(--db-orange); font-family: Bangers, Nunito, sans-serif; font-size: clamp(64px, 14vw, 104px); line-height: 1; letter-spacing: .04em; text-shadow: 3px 3px 0 #173b64; }
.db-not-found-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px 22px; }
.db-not-found-actions .db-news-back { color: var(--db-orange-dark); }
.db-not-found-actions .db-news-back:hover { color: #173b64; }

/* Listado */
.db-news-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 23px; }
.db-news-card { min-width: 0; }
.db-news-card-link {
    display: flex; flex-direction: column; height: 100%; overflow: hidden; color: var(--db-text); text-decoration: none;
    background: #fff1d2; border: 2px solid #132f50; border-top: 4px solid #ff912b; border-radius: 10px;
    box-shadow: 4px 5px 0 #122f50; transition: transform .18s, box-shadow .18s;
}
@media (hover: hover) { .db-news-card-link:hover { transform: translateY(-4px); box-shadow: 4px 9px 0 #122f50; } }
.db-news-cover { display: grid; place-items: center; aspect-ratio: 16 / 9; overflow: hidden; background: #f8e8c5; border-bottom: 1px solid var(--db-border); }
.db-news-cover img { width: 100%; height: 100%; object-fit: cover; }
.db-news-placeholder { display: grid; place-items: center; width: 100%; height: 100%; }
/* Logo de la web sobre el azul de la cabecera, como se ve arriba del todo */
.db-news-placeholder.is-logo { background: radial-gradient(ellipse at 50% 40%, #24405c, transparent 70%), linear-gradient(180deg, #18283c, #111e30); }
.db-news-placeholder.is-logo img { width: 72%; height: auto; }
.db-news-placeholder.is-game svg { width: 42%; height: auto; }
.db-news-card-body { display: flex; flex-direction: column; flex: 1; gap: 8px; padding: 16px 18px 18px; }
.db-news-card-body time, .db-news-article time { color: var(--db-orange-dark); font-size: 12px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.db-news-card-body h2 { margin: 0; color: #173b64; font-size: 24px; line-height: 1.1; }
.db-news-card-body p { margin: 0; color: #4d5b68; font-size: 13.5px; line-height: 1.55; }
.db-news-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.db-news-tags span { padding: 3px 9px; border: 1px solid #d7883580; border-radius: 999px; background: #f58b281f; color: var(--db-orange-dark); font-size: 11px; font-weight: 800; }
.db-news-more { display: inline-flex; align-items: center; gap: 6px; margin-top: auto; padding-top: 4px; color: var(--db-orange-dark); font-size: 13px; font-weight: 900; }
.db-news-card-link:hover .db-news-more i { transform: translateX(3px); }
.db-news-more i { transition: transform .15s; }

.db-news-pagination { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 28px; color: #e0ebef; font-weight: 800; font-size: 14px; }
.db-news-pagination a {
    display: inline-flex; align-items: center; gap: 7px; padding: 8px 15px; border: 1px solid #ffce5966; border-radius: 999px;
    background: #0b182a73; color: #ffe4ad; text-decoration: none;
}
.db-news-pagination a:hover { background: #142337; border-color: #ffce59; color: #ffce59; }

/* Artículo */
.db-news-article-page { width: min(860px, 100%); }
.db-news-breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 16px; font-size: 13px; font-weight: 800; }
.db-news-breadcrumb a { color: #ffe4ad; text-decoration: none; }
.db-news-breadcrumb a:hover { color: #ffce59; text-decoration: underline; }
.db-news-breadcrumb i { color: #ffce5999; font-size: 11px; }
.db-news-article {
    overflow: hidden; border: 2px solid #233f4b; border-top: 4px solid var(--db-orange); border-radius: 14px;
    background: var(--db-surface); box-shadow: var(--db-shadow);
}
.db-news-article-cover { display: block; width: 100%; max-height: 420px; object-fit: cover; border-bottom: 1px solid var(--db-border); }
.db-news-article-placeholder { height: 220px; border-bottom: 3px solid var(--db-orange); background: #f8e8c5; }
.db-news-article-placeholder .is-logo img { width: min(420px, 70%); }
.db-news-article-inner { padding: 28px 36px 34px; }
.db-news-article h1 { margin: 6px 0 12px; color: #173b64; font-size: clamp(30px, 5vw, 44px); line-height: 1.05; }
.db-news-article .db-news-tags { margin-bottom: 18px; }
.db-news-fallback { display: flex; gap: 8px; align-items: center; margin: 0 0 18px; padding: 10px 14px; border-radius: 8px; background: #f8e8c5; color: #4d5b68; font-size: 13px; }
.db-news-body { color: #33434f; font-size: 16px; line-height: 1.75; overflow-wrap: anywhere; }
.db-news-body > :first-child { margin-top: 0; }
.db-news-body > :last-child { margin-bottom: 0; }
.db-news-body p { margin: 0 0 16px; }
.db-news-body :is(h2, h3) { margin: 28px 0 10px; color: #173b64; line-height: 1.15; }
.db-news-body h2 { font-size: 28px; }
.db-news-body h3 { font-size: 22px; }
.db-news-body :is(ul, ol) { margin: 0 0 16px; padding-left: 22px; }
.db-news-body li { margin-bottom: 6px; }
.db-news-body a { color: var(--db-orange-dark); font-weight: 700; }
.db-news-body img { max-width: 100%; height: auto; margin: 6px 0 16px; border-radius: 10px; }
.db-news-body blockquote { margin: 0 0 16px; padding: 10px 16px; border-left: 4px solid var(--db-orange); background: #f8e8c5; border-radius: 0 8px 8px 0; }
.db-news-footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 22px; }
.db-news-back { display: inline-flex; align-items: center; gap: 7px; color: #ffe4ad; font-weight: 800; font-size: 14px; text-decoration: none; }
.db-news-back:hover { color: #ffce59; }

@media (max-width: 900px) {
    .db-news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
}
@media (max-width: 580px) {
    .db-news-grid { grid-template-columns: 1fr; gap: 14px; }
    .db-news-card-body h2 { font-size: 22px; }
    .db-news-empty { padding: 24px 18px; }
    .db-news-article-inner { padding: 20px 18px 24px; }
    .db-news-body { font-size: 15px; }
    .db-news-article-placeholder { height: 150px; }
    .db-news-footer { flex-direction: column-reverse; align-items: stretch; text-align: center; }
    .db-news-footer .db-news-btn { justify-content: center; }
    .db-news-back { justify-content: center; }
}
