/*
Theme Name: PP Alcorcón Premium
Theme URI: https://ppalcorcon.com
Author: Antigravity
Author URI: https://google.com/deepmind
Description: Tema de WordPress altamente optimizado, responsive y totalmente personalizable para el Partido Popular de Alcorcón. Desarrollado a partir de una plantilla de diseño político estratégico con integración de Tailwind CSS y Customizer dinámico.
Version: 1.1.15
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: pp-alcorcon
Tags: custom-menu, featured-images, theme-options, translation-ready, block-styles

* This theme was built by Antigravity under Gemini Advanced Agentic Coding instructions.
*/

/* --- Estilos Visuales del Tema PP Alcorcón --- */

/* Tipografía corporativa PP: Söhne (autohospedada) */
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-Extraleicht.otf') format('opentype');
    font-weight: 200;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-ExtraleichtKursiv.otf') format('opentype');
    font-weight: 200;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-Leicht.otf') format('opentype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-LeichtKursiv.otf') format('opentype');
    font-weight: 300;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-Buch.otf') format('opentype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-BuchKursiv.otf') format('opentype');
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-Kraftig.otf') format('opentype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-KraftigKursiv.otf') format('opentype');
    font-weight: 500;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-Dreiviertelfett.otf') format('opentype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-DreiviertelfettKursiv.otf') format('opentype');
    font-weight: 600;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-Halbfett.otf') format('opentype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-HalbfettKursiv.otf') format('opentype');
    font-weight: 700;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-Fett.otf') format('opentype');
    font-weight: 800;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-FettKursiv.otf') format('opentype');
    font-weight: 800;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-Extrafett.otf') format('opentype');
    font-weight: 900;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Söhne';
    src: url('assets/fonts/sohne/Sohne-ExtrafettKursiv.otf') format('opentype');
    font-weight: 900;
    font-style: italic;
    font-display: swap;
}

body {
    font-family: 'Söhne', 'Inter', ui-sans-serif, system-ui, sans-serif;
}

/* Las imágenes de las cabeceras deben conservar el ancho completo de la ventana. */
.site-main > section.relative > img.absolute,
.site-main > section.relative > div.absolute > img.absolute {
    max-width: none;
}

/* Efectos de tarjeta hover premium */
.card-hover {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.card-hover:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 25px -5px rgba(0, 31, 91, 0.1), 0 10px 10px -5px rgba(0, 31, 91, 0.04);
}

.pp-campaign-card {
    text-decoration: none;
}
.pp-campaign-card:focus-visible {
    outline: 3px solid #93c5fd;
    outline-offset: 5px;
}

/* Compensación barra de administración de WordPress */
.admin-bar header.sticky {
    top: 32px !important;
}
@media screen and (max-width: 782px) {
    .admin-bar header.sticky {
        top: 46px !important;
    }
}

/* Transición del Menú Móvil */
.mobile-menu-transition {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Efecto de Sombra de Texto para Legibilidad */
.shadow-text {
    text-shadow: 2px 2px 10px rgba(0, 15, 45, 0.6);
}

/* ── Paginación del blog ── */
.nav-links {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    flex-wrap: wrap;
    justify-content: center;
}
.nav-links .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 0.75rem;
    border-radius: 9999px;
    font-weight: 700;
    font-size: 0.875rem;
    color: #475569;
    border: 1px solid #e2e8f0;
    background: #fff;
    transition: all 0.2s;
    text-decoration: none;
}
.nav-links .page-numbers:hover {
    background: #1d4ed8;
    color: #fff;
    border-color: #1d4ed8;
}
.nav-links .page-numbers.current {
    background: #1d4ed8;
    color: #fff;
    border-color: #1d4ed8;
}
.nav-links .prev,
.nav-links .next {
    padding: 0 1.25rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}
.nav-links .dots {
    border: none;
    background: transparent;
    color: #94a3b8;
    min-width: auto;
}

/* ── Contenido del artículo (single.php) ── */
.article-body h2 {
    font-size: 1.75rem;
    font-weight: 900;
    color: #0f172a;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}
.article-body h3 {
    font-size: 1.35rem;
    font-weight: 800;
    color: #1e293b;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
}
.article-body p {
    margin-bottom: 1.5rem;
    color: #334155;
}
.article-body a {
    color: #1d4ed8;
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: #93c5fd;
    text-underline-offset: 3px;
    transition: color 0.2s;
}
.article-body a:hover {
    color: #1e40af;
}
.article-body ul,
.article-body ol {
    padding-left: 1.5rem;
    margin-bottom: 1.5rem;
    color: #334155;
}
.article-body ul { list-style: disc; }
.article-body ol { list-style: decimal; }
.article-body li { margin-bottom: 0.5rem; }
.article-body blockquote {
    border-left: 4px solid #1d4ed8;
    padding: 1rem 1.5rem;
    background: #eff6ff;
    border-radius: 0 0.75rem 0.75rem 0;
    margin: 2rem 0;
    font-style: italic;
    color: #1e40af;
    font-weight: 600;
}
.article-body img {
    border-radius: 1rem;
    margin: 2rem 0;
    width: 100%;
    height: auto;
}
.article-body hr {
    border: none;
    border-top: 2px solid #e2e8f0;
    margin: 2.5rem 0;
}

/* ── Scrollbar oculto (categorías nav) ── */
.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}
.scrollbar-hide::-webkit-scrollbar {
    display: none;
}

/* ── FAQ Accordion (single.php) ── */
.pp-faq-section {
    margin-top: 3rem;
    margin-bottom: 2rem;
}
.pp-faq-item {
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    margin-bottom: 0.625rem;
    background: #fff;
    overflow: hidden;
    transition: box-shadow 0.2s;
}
.pp-faq-item:hover {
    box-shadow: 0 4px 16px rgba(29, 78, 216, 0.08);
}
.pp-faq-item[open] {
    border-color: #bfdbfe;
    box-shadow: 0 4px 16px rgba(29, 78, 216, 0.1);
}
.pp-faq-item summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.125rem 1.5rem;
    font-weight: 700;
    font-size: 1rem;
    color: #0f172a;
    cursor: pointer;
    list-style: none;
    user-select: none;
}
.pp-faq-item summary::-webkit-details-marker {
    display: none;
}
.pp-faq-item summary:hover {
    color: #1d4ed8;
}
.pp-faq-icon {
    width: 1.25rem;
    height: 1.25rem;
    flex-shrink: 0;
    color: #1d4ed8;
    transition: transform 0.25s ease;
}
.pp-faq-item[open] .pp-faq-icon {
    transform: rotate(45deg);
}
.pp-faq-answer {
    padding: 0 1.5rem 1.25rem;
    color: #475569;
    font-size: 0.9375rem;
    line-height: 1.75;
}

/* ── Utilidad clamp height ── */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Ajustes para el logotipo del menú */
.custom-logo,
.pp-menu-logo {
    height: clamp(42px, 5vw, 76px) !important;
    width: auto !important;
    max-width: min(28vw, 280px) !important;
    display: block;
    object-fit: contain;
}
.custom-logo-link {
    display: block;
}
@media screen and (max-width: 767px) {
    .custom-logo,
    .pp-menu-logo {
        height: 54px !important;
        max-width: 58vw !important;
    }
}

/* Clases de WordPress requeridas por el Codex */
.aligncenter {
    display: block;
    margin: 1.5em auto;
}
.alignleft {
    float: left;
    margin: 0.5em 1.5em 1.5em 0;
}
.alignright {
    float: right;
    margin: 0.5em 0 1.5em 1.5em;
}
.wp-caption {
    background: #fff;
    border: 1px solid #f0f0f0;
    max-width: 96%;
    padding: 5px 3px 10px;
    text-align: center;
}
.wp-caption img {
    border: 0 none;
    height: auto;
    margin: 0;
    max-width: 98.5%;
    padding: 0;
    width: auto;
}
.wp-caption p.wp-caption-text {
    font-size: 11px;
    line-height: 17px;
    margin: 0;
    padding: 0 4px 5px;
}
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}
.screen-reader-text:focus {
    background-color: #eee;
    clip: auto !important;
    clip-path: none;
    color: #444;
    display: block;
    font-size: 1em;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 15px 23px 14px;
    position: absolute;
    top: 5px;
    width: auto;
    z-index: 100000;
}





/* ── Navegación independiente de noticias y medios ── */
#ultimas-noticias-tarjetas, #apariciones-medios-tarjetas, #medios-tarjetas {
    scroll-margin-top: 6.5rem;
}

.pp-news-pagination {
    border-top: 1px solid #e2e8f0;
    padding-top: 1.25rem;
}
.pp-news-page-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 0.8rem;
    border: 1px solid #dbe3ef;
    border-radius: 0.75rem;
    background: #fff;
    color: #1e3a8a;
    font-size: 0.875rem;
    font-weight: 800;
    text-decoration: none;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.pp-news-page-number:hover,
.pp-news-page-number:focus-visible {
    border-color: #2563eb;
    background: #eff6ff;
    color: #1d4ed8;
    transform: translateY(-1px);
}
.pp-news-page-number.is-current {
    border-color: #1d4ed8;
    background: #1d4ed8;
    color: #fff;
    box-shadow: 0 6px 16px rgba(29, 78, 216, 0.22);
}
.pp-news-page-prev,
.pp-news-page-next {
    padding-left: 1rem;
    padding-right: 1rem;
    color: #475569;
}
.pp-news-page-dots {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.25rem;
    color: #94a3b8;
    font-weight: 800;
}
@media screen and (max-width: 639px) {
    .pp-news-page-number {
        min-width: 2.25rem;
        height: 2.25rem;
        padding: 0 0.65rem;
        border-radius: 0.65rem;
    }
    .pp-news-page-prev,
    .pp-news-page-next {
        padding-left: 0.7rem;
        padding-right: 0.7rem;
    }
}
/* Presentación editorial de las campañas importadas */
.pp-campaign-content {
    max-width: 48rem;
}
.pp-campaign-content > p:first-of-type {
    border-left: 4px solid #2563eb;
    color: #0f2f68;
    font-size: 1.2rem;
    font-weight: 600;
    line-height: 1.7;
    margin-bottom: 2rem;
    padding-left: 1.25rem;
}
.pp-campaign-content h2,
.pp-campaign-content h3 {
    color: #0f2f68;
    line-height: 1.2;
    margin-top: 2.5rem;
}
.pp-campaign-content figure,
.pp-campaign-content .wp-block-image {
    margin: 2rem 0;
}
.pp-campaign-content img {
    border-radius: 0.75rem;
    box-shadow: 0 18px 40px rgba(15, 47, 104, 0.14);
}
.pp-campaign-content a:not(.wp-block-file__button) {
    color: #1d4ed8;
    font-weight: 700;
}

/* Los modelos de las campanas no son las descargas antiguas de las noticias. */
body.single-post .pp-campaign-content .wp-block-file {
    display: block !important;
    margin: 1.5rem 0;
    padding: 1rem;
    border: 1px solid #dbe4ef;
    border-radius: 8px;
    overflow-wrap: anywhere;
}
body.single-post .pp-campaign-content .wp-block-file__button,
body.single-post .pp-campaign-content a[download] {
    display: inline-flex !important;
    align-items: center;
    margin: 0.75rem 0 0;
    padding: 0.65rem 1rem;
    background: #1d4ed8;
    color: #fff;
    border-radius: 6px;
    font-weight: 700;
    text-decoration: none;
}
body.single-post .pp-campaign-content a[download]:focus-visible {
    outline: 3px solid #1d4ed8;
    outline-offset: 3px;
}
