/*
Theme Name: Préstamos Hub
Theme URI: https://localhost
Description: Comparador dinámico de préstamos CPL
Version: 1.0.2
Author: Tu Nombre
Author URI: https://localhost
License: GPL v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: prestamos-hub
Domain Path: /languages
*/

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

#ofertas,
#como-funciona,
#faq {
    scroll-margin-top: 96px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #0a1628;
    background: #f2fdff;
}

:root {
    --brand: #64AEBD;
    --accent: #1066AC;
    --dark: #0a1628;
    --light-gray: #f2fdff;
    --border: #b3d2eb;
    --text-secondary: #5a7184;
}

/* ── Header ──────────────────────────────────────────────────────── */
/* ── Header ──────────────────────────────────────────────────────── */
header {
    background: white;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(10, 22, 40, 0.04);
}

nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0.85rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    text-decoration: none;
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--dark);
    letter-spacing: -0.02em;
    flex-shrink: 0;
}

.logo-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    background: linear-gradient(135deg, var(--brand), var(--accent));
    color: white;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 900;
    box-shadow: 0 2px 6px rgba(16, 102, 172, 0.22);
}

.logo-text {
    color: var(--dark);
    line-height: 1;
}

.logo-accent {
    color: var(--accent);
}

.nav-links {
    display: flex;
    gap: 1.25rem;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.925rem;
    transition: color 0.15s ease, background-color 0.15s ease;
    padding: 0.35rem 0.65rem;
    border-radius: 0.375rem;
}

.nav-links a:hover {
    color: var(--accent);
    background: rgba(16, 102, 172, 0.06);
}

/* ── Main Container ──────────────────────────────────────────────── */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* ── Hero Section ────────────────────────────────────────────────── */
.hero {
    text-align: center;
    margin-bottom: 3rem;
}

.hero h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 2rem;
}

/* ── Search Bar ──────────────────────────────────────────────────── */
.search-container {
    max-width: 600px;
    margin: 2rem auto;
    display: flex;
    gap: 0.5rem;
}

.search-container input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border);
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.search-container input:focus {
    outline: none;
    border-color: var(--accent);
}

.search-container button {
    padding: 0.75rem 1.5rem;
    background: var(--brand);
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.search-container button:hover {
    background: #4f9aab;
}

/* ── Filter Tabs ─────────────────────────────────────────────────── */
.filter-tabs {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.filter-tabs button {
    padding: 0.75rem 1.5rem;
    border: 2px solid var(--border);
    background: white;
    border-radius: 9999px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.2s;
}

.filter-tabs button:hover,
.filter-tabs button.active {
    border-color: var(--brand);
    background: var(--brand);
    color: white;
}

/* ── Stats Bar ───────────────────────────────────────────────────── */
.stats-bar {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
    text-align: center;
}

.stat-box {
    background: white;
    padding: 1.5rem;
    border: 1px solid var(--border);
    border-radius: 0.75rem;
}

.stat-box dt {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-secondary);
    font-weight: 600;
    letter-spacing: 0.05em;
}

.stat-box dd {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent);
    margin-top: 0.5rem;
}

/* ── Offer Grid ──────────────────────────────────────────────────– */
.offers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
    margin: 3rem 0;
    align-items: stretch;
}

.offer-card {
    background: white;
    border: 1px solid var(--border);
    border-left: 4px solid var(--brand);
    border-radius: 0.75rem;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    box-sizing: border-box;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-left-color 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.offer-card:hover {
    box-shadow: 0 6px 18px rgba(16, 102, 172, 0.12);
    border-left-color: var(--accent);
    transform: translateY(-2px);
}

.offer-header {
    display: flex;
    gap: 0.85rem;
    margin-bottom: 0.75rem;
    align-items: flex-start;
}

.offer-logo {
    width: 48px;
    height: 48px;
    background: #e8f7fb;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--brand);
    flex-shrink: 0;
    overflow: hidden;
}

.offer-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.offer-title {
    flex: 1;
    min-width: 0;
}

.offer-title h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 0.2rem;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.offer-title h3 a {
    color: inherit;
    text-decoration: none;
}

.offer-title h3 a:hover {
    color: var(--accent);
}

.offer-description {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.35;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.7em;
    max-height: 2.7em;
}

.offer-badge {
    display: inline-block;
    background: #e0f4f9;
    color: var(--accent);
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 0.2rem 0.45rem;
    border-radius: 0.25rem;
    margin-left: auto;
    flex-shrink: 0;
}

.offer-specs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin: 1rem 0;
    padding: 0.85rem 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    min-height: 4.25rem;
    align-items: start;
}

.spec {
    font-size: 0.8rem;
    min-width: 0;
}

.spec-label {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    display: block;
    margin-bottom: 0.2rem;
}

.spec-value {
    color: var(--dark);
    font-weight: 700;
    font-size: 0.825rem;
    line-height: 1.25;
    display: block;
    word-break: break-word;
}

.offer-cta {
    margin-top: auto;
    padding: 0.75rem 1rem;
    background: var(--brand);
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    transition: background 0.2s, transform 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
}

.offer-cta:hover {
    background: var(--accent);
    color: white;
}

/* ── Trust Badges ────────────────────────────────────────────────– */
.trust-badges {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin: 2rem 0;
    flex-wrap: wrap;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.badge svg {
    width: 20px;
    height: 20px;
    color: var(--brand);
    flex-shrink: 0;
}

/* ── Footer ──────────────────────────────────────────────────────– */
footer {
    background: white;
    border-top: 1px solid var(--border);
    margin-top: 4rem;
    padding: 2rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: var(--accent);
}

.compliance {
    border-top: 1px solid var(--border);
    padding-top: 2rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.compliance p {
    margin-bottom: 1rem;
}

/* ── AdX Banner ──────────────────────────────────────────────────– */
.adx-banner {
    margin: 2rem 0;
    text-align: center;
}

.ad-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(0, 0, 0, 0.3);
    margin-bottom: 0.5rem;
}

.ad-container {
    min-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    max-width: 350px;
    background: transparent;
    border: none;
    box-shadow: none;
}

/* ── Blog Styles ────────────────────────────────────────────────── */
.blog-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.blog-header {
    text-align: center;
    margin-bottom: 3rem;
}

.blog-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 0.5rem;
}

.blog-header p {
    font-size: 0.95rem;
    color: var(--text-secondary);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.blog-post-featured {
    grid-column: 1 / -1;
    background: white;
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.blog-post-featured:hover {
    box-shadow: 0 8px 24px rgba(100, 174, 189, 0.15);
    border-color: var(--brand);
}

.blog-post-featured .post-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

.blog-post-featured .post-image {
    width: 100%;
    aspect-ratio: 21 / 9;
    max-height: 420px;
    overflow: hidden;
    background: var(--light-gray);
}

.blog-post-featured .post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.blog-post-featured:hover .post-image img {
    transform: scale(1.05);
}

.blog-post-featured .post-content {
    padding: 1.5rem;
}

.blog-post-featured .post-category {
    display: inline-block;
    background: #e0f4f9;
    color: var(--brand);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    padding: 0.35rem 0.65rem;
    border-radius: 9999px;
    margin-bottom: 0.75rem;
}

.blog-post-featured h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark);
    line-height: 1.3;
    margin-bottom: 0.75rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.blog-post-featured:hover h2 {
    color: var(--brand);
}

.blog-post-featured .post-excerpt {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 1rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.blog-post-featured time {
    font-size: 0.8rem;
    color: #7a9aae;
}

/* Posts regulares en grid */
.blog-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.blog-post-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.blog-post-card:hover {
    box-shadow: 0 8px 24px rgba(100, 174, 189, 0.15);
    border-color: var(--brand);
}

.blog-post-card .post-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.blog-post-card .post-image {
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: var(--light-gray);
}

.blog-post-card .post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.blog-post-card:hover .post-image img {
    transform: scale(1.05);
}

.blog-post-card .post-content {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.blog-post-card .post-category {
    display: inline-block;
    background: #e0f4f9;
    color: var(--brand);
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    padding: 0.3rem 0.6rem;
    border-radius: 9999px;
    margin-bottom: 0.75rem;
    width: fit-content;
}

.blog-post-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--dark);
    line-height: 1.3;
    margin-bottom: 0.5rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.blog-post-card:hover h3 {
    color: var(--brand);
}

.blog-post-card .post-excerpt {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
    margin-bottom: 0.75rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    flex: 1;
}

.blog-post-card time {
    font-size: 0.75rem;
    color: #7a9aae;
    margin-bottom: 0.75rem;
}

.blog-post-card .read-more {
    color: var(--brand);
    font-weight: 600;
    font-size: 0.8rem;
    transition: color 0.2s ease;
}

.blog-post-card:hover .read-more {
    color: var(--accent);
}

/* Single post styles */
.single-post-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
}

article.single-post {
    background: white;
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    overflow: hidden;
}

.post-header {
    padding: 2rem;
    border-bottom: 1px solid var(--border);
}

.post-header .post-category {
    display: inline-block;
    background: #e0f4f9;
    color: var(--brand);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    padding: 0.35rem 0.65rem;
    border-radius: 9999px;
    margin-bottom: 1rem;
}

.post-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--dark);
    line-height: 1.3;
    margin-bottom: 1rem;
}

.post-meta {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.post-featured-image {
    width: 100%;
    max-height: 400px;
    overflow: hidden;
}

.post-featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-body {
    padding: 2rem;
    line-height: 1.8;
}

.post-body p {
    margin-bottom: 1.5rem;
    color: var(--dark);
}

.post-body h2,
.post-body h3 {
    color: var(--dark);
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.post-body h2 {
    font-size: 1.5rem;
}

.post-body h3 {
    font-size: 1.25rem;
}

.post-body ul,
.post-body ol {
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.post-body li {
    margin-bottom: 0.5rem;
}

.post-body img {
    max-width: 100%;
    height: auto;
    margin: 1.5rem 0;
    border-radius: 0.5rem;
}

.post-footer {
    padding: 1.5rem 2rem;
    border-top: 1px solid var(--border);
}

.back-to-blog {
    color: var(--brand);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.back-to-blog:hover {
    color: var(--accent);
}

.blog-pagination {
    text-align: center;
    margin: 3rem 0;
}

.blog-pagination a,
.blog-pagination span {
    display: inline-block;
    padding: 0.5rem 1rem;
    margin: 0.25rem;
    color: var(--text-secondary);
    text-decoration: none;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    transition: all 0.2s;
}

.blog-pagination a:hover {
    color: white;
    background: var(--brand);
    border-color: var(--brand);
}

.blog-pagination .page-numbers.current {
    background: var(--brand);
    color: white;
    border-color: var(--brand);
}

/* ── Detalle de oferta en posts generados ────────────────────────– */
.offer-detail {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.offer-hero-card {
    background: white;
    border: 1px solid var(--border);
    border-left: 4px solid var(--accent);
    border-radius: 0.75rem;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    position: relative;
}

.offer-hero-ad {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    background: #f2fdff;
    border: 1px solid var(--border);
    padding: 0.2rem 0.45rem;
    border-radius: 0.25rem;
}

.offer-hero-header {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.offer-detail-logo {
    width: 72px;
    height: 72px;
    flex-shrink: 0;
    background: #e8f7fb;
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.offer-detail-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.offer-detail-logo-initial {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--brand);
}

.offer-hero-heading {
    flex: 1;
}

.offer-detail-company {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
}

.offer-detail-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--dark);
    line-height: 1.25;
    margin-bottom: 0.5rem;
}

.offer-detail-badge {
    display: inline-block;
    background: #e0f4f9;
    color: var(--accent);
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
}

.offer-hero-description {
    color: var(--dark);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.offer-hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.offer-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: #f2fdff;
    color: var(--dark);
    font-size: 0.8rem;
    font-weight: 500;
    padding: 0.4rem 0.7rem;
    border: 1px solid var(--border);
    border-radius: 9999px;
}

.offer-hero-badge span {
    color: var(--brand);
    font-weight: 700;
}

.offer-hero-specs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 0.75rem;
    margin: 1rem 0;
}

.offer-hero-spec {
    background: var(--light-gray);
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    padding: 0.75rem;
    text-align: center;
}

.offer-hero-spec span {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 0.25rem;
}

.offer-hero-spec strong {
    display: block;
    font-size: 1.1rem;
    color: var(--dark);
    font-weight: 700;
}

.offer-hero-cta {
    display: block;
    width: 100%;
    margin-top: 1rem;
    padding: 0.85rem;
    background: var(--brand);
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    transition: background 0.2s;
}

.offer-hero-cta:hover {
    background: #4f9aab;
}

.offer-hero-redirect {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
    margin-bottom: 0;
}

.offer-detail-sections {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.offer-detail-section {
    background: white;
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    padding: 1.25rem;
}

.offer-detail-section h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 0.75rem;
}

.offer-detail-section p,
.offer-detail-section ul {
    margin-bottom: 0;
    color: var(--dark);
}

.offer-detail-list {
    list-style: none;
    margin-left: 0 !important;
}

.offer-detail-list li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
}

.offer-detail-list li:last-child {
    margin-bottom: 0;
}

.offer-detail-list-ok li::before {
    content: "\2713";
    position: absolute;
    left: 0;
    color: #22c55e;
    font-weight: 700;
}

.offer-detail-list-ko li::before {
    content: "\2717";
    position: absolute;
    left: 0;
    color: #ef4444;
    font-weight: 700;
}

.offer-detail-note {
    font-size: 0.8rem;
    color: var(--text-secondary);
    border-top: 1px solid var(--border);
    padding-top: 1rem;
    margin-bottom: 0;
}

/* ── Responsive ──────────────────────────────────────────────────– */
@media (max-width: 768px) {
    .offer-hero-header {
        flex-direction: column;
    }

    .offer-hero-specs {
        grid-template-columns: 1fr 1fr;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

    nav {
        padding: 0.75rem 1rem;
        flex-wrap: wrap;
        gap: 0.75rem;
    }

    .logo {
        font-size: 1.1rem;
    }

    .logo-badge {
        width: 30px;
        height: 30px;
        font-size: 0.95rem;
    }

    .market-switcher {
        margin-left: auto;
    }

    .market-switcher select {
        padding: 0.35rem 1.6rem 0.35rem 0.6rem;
        font-size: 0.8rem;
    }

    .nav-links {
        order: 3;
        width: 100%;
        display: flex;
        justify-content: flex-start;
        gap: 0.5rem;
        overflow-x: auto;
        padding: 0.25rem 0 0.5rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .nav-links::-webkit-scrollbar {
        display: none;
    }

    .nav-links li {
        flex-shrink: 0;
    }

    .nav-links a {
        font-size: 0.825rem;
        white-space: nowrap;
        padding: 0.3rem 0.6rem;
        background: rgba(16, 102, 172, 0.05);
        border-radius: 999px;
    }

    main {
        padding: 1rem;
    }

    .offers-grid {
        grid-template-columns: 1fr;
    }

    .search-container {
        flex-direction: column;
    }

    .trust-badges {
        gap: 1rem;
    }

    .blog-grid {
        grid-template-columns: 1fr;
    }

    .blog-posts-grid {
        grid-template-columns: 1fr;
    }

    .single-post-container {
        padding: 1rem;
    }

    .post-header {
        padding: 1.5rem;
    }

    .post-body {
        padding: 1.5rem;
    }
}

/* ── Selector de mercado (país e idioma) ──────────────────────────– */
.market-switcher {
    margin-left: 0;
    flex-shrink: 0;
}

.market-switcher select {
    appearance: none;
    -webkit-appearance: none;
    padding: 0.45rem 2rem 0.45rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    background-color: white;
    color: var(--dark);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%231066AC'%3E%3Cpath d='M5.5 7.5 10 12l4.5-4.5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.6rem center;
    background-size: 1.1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.market-switcher select:hover {
    border-color: var(--accent);
}

.market-switcher select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(16, 102, 172, 0.15);
}

/* ── Estilos para Páginas Legales y de Contacto ──────────────────── */
.offer-card:has(.legal-content),
.offer-card:has(.contact-page-container) {
    max-width: 900px;
    margin: 0 auto 3rem;
    padding: 2.5rem;
    display: block;
    line-height: 1.75;
    color: #1e293b;
    border-left: 5px solid var(--accent);
}

.legal-content h2 {
    font-size: 1.35rem;
    color: var(--dark);
    margin: 2rem 0 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border);
    font-weight: 700;
}

.legal-content h3 {
    font-size: 1.15rem;
    color: var(--accent);
    margin: 1.5rem 0 0.5rem;
    font-weight: 600;
}

.legal-content p {
    margin-bottom: 1.1rem;
    font-size: 1rem;
}

.legal-content ul, .legal-content ol {
    margin: 0 0 1.5rem 1.5rem;
    padding-left: 0.5rem;
}

.legal-content li {
    margin-bottom: 0.5rem;
}

.legal-content a {
    color: var(--accent);
    text-decoration: underline;
}

.legal-notice-box {
    background-color: #f0f9fb;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    padding: 1.25rem 1.5rem;
    margin: 1.5rem 0;
}

.legal-notice-box ul {
    margin-bottom: 0;
}

.legal-alert-box {
    background-color: #fefce8;
    border: 1px solid #fef08a;
    border-left: 4px solid #ca8a04;
    border-radius: 0.5rem;
    padding: 1.25rem 1.5rem;
    margin: 1.5rem 0;
}

.legal-alert-box ul {
    margin-bottom: 0;
}

/* Tabla de cookies */
.cookies-table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    font-size: 0.95rem;
}

.cookies-table th, .cookies-table td {
    padding: 0.85rem 1rem;
    border: 1px solid var(--border);
    text-align: left;
}

.cookies-table th {
    background-color: #e8f7fb;
    color: var(--dark);
    font-weight: 700;
}

.cookies-table tr:nth-child(even) {
    background-color: #fbfdff;
}

/* Página de Contacto */
.contact-intro {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    text-align: center;
}

.contact-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.contact-card {
    background: #f8fcfe;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    padding: 1.5rem;
    text-align: center;
}

.contact-card-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.contact-card h3 {
    font-size: 1.1rem;
    color: var(--dark);
    margin-bottom: 0.25rem;
}

.contact-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.contact-card a {
    color: var(--accent);
    text-decoration: none;
    word-break: break-all;
}

.contact-form-wrapper {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    padding: 2rem;
    margin-top: 1rem;
}

.contact-form-wrapper h2 {
    font-size: 1.4rem;
    color: var(--dark);
    margin-bottom: 1.5rem;
    text-align: center;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 0.4rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
    background-color: #ffffff;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(16, 102, 172, 0.15);
}

.form-privacy-consent {
    margin: 1.25rem 0;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    cursor: pointer;
}

.checkbox-label input {
    margin-top: 0.25rem;
    accent-color: var(--accent);
}

.contact-submit-btn {
    display: inline-block;
    width: 100%;
    padding: 0.9rem 1.5rem;
    background: var(--brand);
    color: white;
    font-size: 1.05rem;
    font-weight: 700;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: background-color 0.2s, transform 0.1s;
}

.contact-submit-btn:hover {
    background: #4f9aab;
}

.form-alert-success {
    margin-top: 1.25rem;
    padding: 1rem 1.25rem;
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;
    border-radius: 0.5rem;
    font-weight: 600;
    text-align: center;
}

@media (max-width: 640px) {
    .form-row {
        grid-template-columns: 1fr;
    }
    .offer-card:has(.legal-content),
    .offer-card:has(.contact-page-container) {
        padding: 1.5rem;
    }
}

/* ── Estilos Next Power Hub para Posts de Ofertas ────────────────── */
.single-post-offer {
    max-width: 820px !important;
    margin: 0 auto !important;
    background: transparent !important;
    padding: 0 !important;
    box-shadow: none !important;
    border: none !important;
}

.post-body-offer {
    padding: 0 !important;
}

.nexpower-item {
    font-family: inherit;
    color: #0a1628;
    line-height: 1.6;
}

.item-top-nav {
    margin-bottom: 0.75rem;
}

.item-back-link {
    font-size: 0.825rem;
    color: #5a7184;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.15s;
}

.item-back-link:hover {
    color: #1066ac;
}

.item-header-block {
    background: #ffffff;
    border: 1px solid #b3d2eb;
    border-radius: 0.75rem;
    padding: 1.75rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.item-title-row {
    display: flex;
    gap: 1.25rem;
    align-items: center;
}

.item-logo {
    width: 64px;
    height: 64px;
    border-radius: 0.5rem;
    background: #e8f7fb;
    border: 1px solid #b3d2eb;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.item-logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.item-logo-initial {
    font-size: 1.75rem;
    font-weight: 800;
    color: #1066ac;
}

.item-heading-text {
    flex: 1;
}

.item-category-pill {
    display: inline-block;
    background: #e0f4f9;
    color: #1066ac;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    margin-bottom: 0.35rem;
}

.item-title {
    font-size: 1.85rem;
    font-weight: 800;
    color: #0a1628;
    line-height: 1.15;
    margin: 0;
}

.item-company {
    display: block;
    font-size: 0.9rem;
    color: #5a7184;
    margin-top: 0.15rem;
}

.item-updated-date {
    display: block;
    font-size: 0.75rem;
    color: #7a9aae;
    margin-top: 0.25rem;
}

.item-description-summary {
    font-size: 0.95rem;
    color: #475569;
    line-height: 1.6;
    margin: 1.1rem 0;
}

.item-trust-signals {
    border-top: 1px solid #f1f5f9;
    border-bottom: 1px solid #f1f5f9;
    padding: 0.6rem 0;
    margin-bottom: 1rem;
}

.item-trust-notice {
    font-size: 0.75rem;
    color: #7a9aae;
    margin: 0;
}

.item-feature-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.item-feature-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: #ecfdf5;
    color: #065f46;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.35rem 0.75rem;
    border-radius: 9999px;
}

.pill-check-icon {
    width: 14px;
    height: 14px;
    color: #10b981;
    flex-shrink: 0;
}

/* ── Hero Sticky CTA Bar ─────────────────────────────────────────── */
.item-sticky-cta-banner {
    background: #ffffff;
    border: 1px solid #b3d2eb;
    border-radius: 0.75rem;
    box-shadow: 0 4px 14px rgba(16, 102, 172, 0.08);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.sticky-banner-inner {
    background: linear-gradient(90deg, #64aebd, #1066ac);
    padding: 1rem 1.4rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.sticky-specs-group {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.sticky-spec-item {
    color: #ffffff;
}

.sticky-label {
    display: block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 0.15rem;
}

.sticky-val {
    font-size: 1.4rem;
    font-weight: 800;
    color: #ffffff;
    display: block;
    line-height: 1.2;
}

.sticky-border-left {
    border-left: 1px solid rgba(255, 255, 255, 0.35);
    padding-left: 1.5rem;
}

.sticky-cta-btn {
    background: #ffffff;
    color: #1066ac;
    padding: 0.7rem 1.4rem;
    border-radius: 0.5rem;
    font-weight: 700;
    font-size: 0.925rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: background 0.15s, transform 0.1s;
}

.sticky-cta-btn:hover {
    background: #e0f4f9;
}

.cta-footnote {
    font-size: 0.75rem;
    color: #7a9aae;
    padding: 0.45rem 1.4rem;
    background: #fafcff;
    margin: 0;
    border-top: 1px solid #eef4f9;
}

/* ── 4 Tarjetas de Especificaciones ─────────────────────────────── */
.item-specs-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.spec-card-box {
    background: #cff0f8;
    border: 1px solid #b3d2eb;
    border-radius: 0.6rem;
    padding: 0.85rem 1rem;
    text-align: left;
}

.spec-name {
    display: block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #5a7184;
    font-weight: 600;
    margin-bottom: 0.35rem;
}

.spec-number {
    display: block;
    font-size: 1.15rem;
    font-weight: 800;
}

.spec-brand {
    color: #1066ac;
}

.spec-dark {
    color: #0a1628;
}

/* ── Nuestro Veredicto ───────────────────────────────────────────── */
.item-verdict-box {
    background: #e0f4f9;
    border: 1px solid #64aebd;
    border-radius: 0.75rem;
    padding: 1.35rem 1.5rem;
    margin-bottom: 1.5rem;
}

.verdict-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1066ac;
    margin: 0 0 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.verdict-icon {
    width: 18px;
    height: 18px;
    color: #1066ac;
    flex-shrink: 0;
}

.verdict-body {
    font-size: 0.925rem;
    color: #1e3a5f;
    line-height: 1.6;
    margin: 0;
}

/* ── Ventajas vs Contras Grid ────────────────────────────────────── */
.item-pros-cons-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.pros-box {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 0.75rem;
    padding: 1.25rem 1.5rem;
}

.pros-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #166534;
    margin: 0 0 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.pros-icon {
    width: 18px;
    height: 18px;
    color: #166534;
    flex-shrink: 0;
}

.pros-items {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.pros-items li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #15803d;
    line-height: 1.45;
}

.pro-check-svg {
    width: 16px;
    height: 16px;
    color: #22c55e;
    flex-shrink: 0;
    margin-top: 2px;
}

.cons-box {
    background: #fff7ed;
    border: 1px solid #fed7aa;
    border-radius: 0.75rem;
    padding: 1.25rem 1.5rem;
}

.cons-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #9a3412;
    margin: 0 0 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.cons-icon {
    width: 18px;
    height: 18px;
    color: #9a3412;
    flex-shrink: 0;
}

.cons-items {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.cons-items li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #c2410c;
    line-height: 1.45;
}

.con-warn-svg {
    width: 16px;
    height: 16px;
    color: #f97316;
    flex-shrink: 0;
    margin-top: 2px;
}

/* ── Mejor Para & Requisitos Cards ───────────────────────────────── */
.item-card-simple {
    background: #ffffff;
    border: 1px solid #b3d2eb;
    border-radius: 0.75rem;
    padding: 1.35rem 1.5rem;
    margin-bottom: 1.5rem;
}

.card-simple-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #0a1628;
    margin: 0 0 0.6rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.card-icon-brand {
    width: 18px;
    height: 18px;
    color: #64aebd;
    flex-shrink: 0;
}

.card-simple-desc {
    font-size: 0.925rem;
    color: #5a7184;
    line-height: 1.6;
    margin: 0;
}

.requirements-items {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.requirements-items li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #334155;
    line-height: 1.45;
}

.req-check-svg {
    width: 16px;
    height: 16px;
    color: #64aebd;
    flex-shrink: 0;
    margin-top: 2px;
}

/* ── Guía Editorial (Prose) ──────────────────────────────────────── */
.item-editorial-body {
    background: #ffffff;
    border: 1px solid #b3d2eb;
    border-radius: 0.75rem;
    padding: 1.75rem 2rem;
    margin-bottom: 1.5rem;
    line-height: 1.75;
    color: #334155;
}

.item-editorial-body h2 {
    font-size: 1.35rem;
    font-weight: 700;
    color: #0a1628;
    margin: 1.75rem 0 0.6rem;
    border-bottom: 1px solid #eef4f9;
    padding-bottom: 0.4rem;
}

.item-editorial-body h2:first-child {
    margin-top: 0;
}

.item-editorial-body p {
    margin-bottom: 1.1rem;
    font-size: 0.95rem;
}

.item-steps-list {
    margin: 0.75rem 0 1.5rem 1.5rem;
    padding: 0;
}

.item-steps-list li {
    margin-bottom: 0.6rem;
    font-size: 0.95rem;
}

/* ── Bottom Conversion CTA Box ───────────────────────────────────── */
.item-bottom-cta-box {
    background: #ffffff;
    border: 1px solid #b3d2eb;
    border-radius: 0.75rem;
    padding: 1.5rem 1.75rem;
    margin-top: 2rem;
    margin-bottom: 2rem;
}

.bottom-cta-inner {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    align-items: center;
    justify-content: space-between;
}

@media (min-width: 640px) {
    .bottom-cta-inner {
        flex-direction: row;
    }
}

.bottom-disclaimer {
    font-size: 0.75rem;
    color: #7a9aae;
    line-height: 1.5;
    margin: 0;
    max-width: 480px;
}

.bottom-cta-btn {
    background: #64aebd;
    color: #ffffff;
    padding: 0.85rem 2rem;
    border-radius: 0.5rem;
    font-weight: 700;
    font-size: 0.95rem;
    text-decoration: none;
    text-align: center;
    white-space: nowrap;
    transition: background 0.15s, transform 0.1s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.bottom-cta-btn:hover {
    background: #4f9aab;
}

@media (max-width: 768px) {
    .item-specs-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .item-pros-cons-grid {
        grid-template-columns: 1fr;
    }
    .sticky-specs-group {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.6rem;
    }
    .sticky-border-left {
        border-left: none;
        padding-left: 0;
        border-top: 1px solid rgba(255, 255, 255, 0.35);
        padding-top: 0.6rem;
    }
    .sticky-cta-btn {
        width: 100%;
        justify-content: center;
    }
    .sticky-cta-action {
        width: 100%;
    }
    .item-header-block,
    .item-editorial-body {
        padding: 1.25rem;
    }
}

