/*
Theme Name: PATERNA_INFO
Theme URI: https://ellorens.net
Version: 1.0
Description: Tema hijo de PATERNA_INFO
Author: ellorens
Author URI: https://ellorens.net
Template: dt-the7
*/

/* ============================================================
   Paleta cerámica de Paterna
   ============================================================ */

:root {
    --bg:           #FBF7EE;   /* cerámica sin cocer */
    --surface:      #FFFFFF;
    --surface-2:    #F3ECDD;   /* raised muted */
    --ink:          #241429;   /* manganeso */
    --ink-2:        #5A4A5F;
    --muted:        #8E8189;
    --rule:         #E8DFCC;
    --rule-strong:  #D5C8AC;
    --accent:       #3D6B3A;   /* verde de Paterna (óxido de cobre) */
    --accent-ink:   #E9F1DD;
    --accent-2:     #7A2E36;   /* rojo cerámica cocida */
    --clay:         #B0764A;

    --radius:       12px;
    --radius-sm:    8px;
    --radius-pill:  999px;

    --shadow-sm:    0 1px 2px rgba(36, 20, 41, .05),
                    0 2px 6px  rgba(36, 20, 41, .04);
    --shadow-md:    0 2px 4px rgba(36, 20, 41, .06),
                    0 10px 24px rgba(36, 20, 41, .07);
    --shadow-lg:    0 4px 8px rgba(36, 20, 41, .08),
                    0 20px 40px rgba(36, 20, 41, .10);

    --t:            180ms ease;

    --font-title:   "Cormorant Garamond", Georgia, "Times New Roman", serif;
    --font-body:    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* ============================================================
   Reglas generales del theme (heredadas)
   ============================================================ */

em {
    color: var(--accent);
}

b, strong {
    font-weight: 600;
}

.same-logo,
.preload-me {
    width: 180px;
    height: auto !important;
}

/* Titulares de artículos de blog (scopeado para no afectar cards) */
.articles-list h3 {
    font-size: 24px !important;
}

.articles-list h3,
.articles-list h4 {
    color: #000;
    font-weight: normal;
}

article {
    margin-bottom: 25px !important;
}

/* Testimonios */
.testimonials-carousel .dt-owl-item-inner .dt-owl-item-image {
    width: 150px !important;
    margin-bottom: 0 !important;
}

/* Contact Form 7 */
.column-full.boton-enviar {
    margin-top: 40px;
    text-align: center;
}

.wpcf7-form-control.wpcf7-submit.has-spinner.boton-enviar {
    max-width: 340px;
    width: 100%;
}

.wpcf7-form-control.wpcf7-text.wpcf7-validates-as-required {
    height: 45px;
}

.cf7-columnas {
    display: flex;
    gap: 20px;
}

.cf7-columnas .col {
    width: 50%;
}

@media (max-width: 768px) {
    .cf7-columnas {
        flex-direction: column;
    }

    .cf7-columnas .col {
        width: 100%;
    }
}

/* Footer */
.enlaces-footer a {
    font-size: 15px;
}

.footer .textwidget a:not(.dt-btn):hover {
    color: #fff !important;
}

.textwidget.custom-html-widget {
    text-align: center;
}

.footer .custom-categories a:hover span.item-name,
.footer .cat-item a:hover span.item-name,
.footer .custom-menu a:hover,
.footer .custom-menu li.act > a,
.footer .widget_recent_comments a:hover {
    color: #ffffff !important;
}

/* Elementor image shadow */
.elementor-animation-bounce-out.attachment-large.size-large {
    box-shadow: 0px 1px 8px 3px rgba(0, 0, 0, 0.20);
}

/* Redes sociales */
.redes-sociales {
    margin-top: 25px !important;
}

.redes-sociales a {
    margin-right: 3px;
}

/* Landing / hero */
.h1-landing h1 {
    text-align: left !important;
    line-height: 0.9em !important;
}

/* Ocultar meta oculto */
a.data-link {
    display: none;
}

/* ============================================================
   Contenedor y titulares base del directorio
   ============================================================ */

.contenedor {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0;
}

body {
    background: var(--bg);
    color: var(--ink);
    font-family: var(--font-body);
}

h2 {
    font-size: clamp(1.4rem, 2.4vw, 1.75rem);
    font-weight: 600;
    margin: 2rem 0 .75rem;
}

h3 {
    font-size: 1.15rem;
    font-weight: 600;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color var(--t);
}

a:hover {
    color: var(--accent-2);
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Buscador
   ============================================================ */

.buscador {
    background: var(--surface);
    border: 1px solid var(--rule);
    border-radius: 0;
    padding: 20px 22px;
    margin: 20px 0 30px;
    box-shadow: var(--shadow-sm);
}

.buscador form {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 14px;
    align-items: end;
}

.buscador label {
    display: block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--ink-2);
    margin-bottom: 6px;
    font-weight: 600;
}

.buscador label strong {
    font-weight: 600;
}

.buscador input[type="text"],
.buscador select {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--rule-strong);
    background: var(--surface);
    color: var(--ink);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 15px;
    transition: border-color var(--t), box-shadow var(--t);
    margin-bottom: 0;
    min-width: 0;
}

.buscador input[type="text"]:focus,
.buscador select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(61, 107, 58, .15);
}

.buscador select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L6 6L11 1' stroke='%235A4A5F' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
}

.btn-buscar {
    background: var(--accent);
    color: var(--accent-ink);
    border: none;
    border-radius: var(--radius-sm);
    padding: 11px 20px;
    font-size: 15px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: background var(--t), transform var(--t);
    box-shadow: var(--shadow-sm);
}

.btn-buscar i {
    font-size: 16px;
}

.btn-buscar:hover {
    background: #2f5530;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-buscar:active {
    transform: translateY(0);
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Grid & Cards
   ============================================================ */

.grid-comercios {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin: 30px 0 60px;
}

.comercio-card {
    background: var(--surface);
    border: 1px solid var(--rule);
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: transform var(--t), box-shadow var(--t), border-color var(--t);
    box-shadow: var(--shadow-sm);
}

.comercio-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--rule-strong);
}

.comercio-card img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    display: block;
    background: var(--surface-2);
}

.comercio-card h3 {
    font-family: var(--font-title);
    font-size: 1.35rem;
    font-weight: 600;
    padding: 14px 18px 0;
    margin: 0;
    color: var(--ink);
}

.comercio-card h3 a {
    font-family: "Instrument Serif", Georgia, "Times New Roman", serif;
    font-size: 1.35rem !important;
    font-weight: 500 !important;
    color: var(--ink);
}

.mobile-header-bar .mobile-branding img {
    max-width: 80% !important;
    height: auto;
}

.comercio-card h3 a:hover {
    color: var(--accent);
}

span.caja-direccion {
    display: block;
    padding: 6px 18px 12px;
    color: var(--ink-2);
    font-size: 13px;
    line-height: 1.4;
    text-transform: uppercase;
    letter-spacing: .02em;
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Iconos de acción en la card
   ============================================================ */

.comercio-icons {
    display: flex;
    gap: 4px;
    padding: 10px 12px;
    border-top: 1px solid var(--rule);
    margin-top: auto;
    background: var(--surface-2);
}

.comercio-icons a,
.comercio-icons button {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    color: var(--ink-2);
    background: transparent;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 17px;
    cursor: pointer;
    text-decoration: none;
    transition: background var(--t), color var(--t);
}

.comercio-icons button {
    all: unset;
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    color: var(--ink-2);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 17px;
    transition: background var(--t), color var(--t);
}

.comercio-icons a:hover,
.comercio-icons button:hover {
    background: var(--surface);
    color: var(--accent);
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Badges (suscripción + verificado)
   ============================================================ */

.comercio-card {
    position: relative;
    padding-top: 25px !important;
}

.etiqueta-suscripcion {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 12px;
    border-radius: var(--radius-pill);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #fff;
    z-index: 2;
    box-shadow: var(--shadow-sm);
}

.badge-featured {
    background: var(--accent);
    color: var(--accent-ink);
}

.badge-premium {
    background: var(--clay);
    color: #fff;
}

.etiqueta-verificado {
    display: inline-block;
    padding: 4px 10px;
    background: var(--accent-ink);
    color: var(--accent);
    border: 1px solid var(--accent);
    border-radius: var(--radius-pill);
    font-size: 12px;
    font-weight: 600;
    margin: 8px 0;
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Paginación
   ============================================================ */

.pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin: 40px 0;
    flex-wrap: wrap;
}

.pagination .page-numbers,
.pagination a,
.pagination span {
    min-width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    background: var(--surface);
    color: var(--ink);
    border: 1px solid var(--rule);
    border-radius: var(--radius-sm);
    text-decoration: none;
    font-weight: 500;
    transition: all var(--t);
    margin: 0;
}

.pagination .page-numbers:hover,
.pagination a:hover {
    background: var(--surface-2);
    border-color: var(--rule-strong);
    color: var(--ink);
}

.pagination .page-numbers.current,
.pagination .current {
    background: var(--accent);
    color: var(--accent-ink);
    border-color: var(--accent);
}

.pagination .page-numbers.dots {
    background: transparent;
    border: none;
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Single (layout)
   ============================================================ */

.comercio-single {
    max-width: 1100px;
    margin: 0 auto;
    padding: 30px 20px 60px;
}

.comercio-title {
    text-align: center;
    margin: 40px 0 30px;
    font-size: clamp(2rem, 4vw, 2.75rem);
    position: relative;
    padding-bottom: 20px;
    font-family: var(--font-title);
    font-weight: 600;
    color: var(--ink);
}

.comercio-title::after {
    content: "";
    display: block;
    width: 60px;
    height: 3px;
    background: var(--clay);
    margin: 18px auto 0;
    border-radius: 2px;
}

.comercio-layout {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto 50px;
    padding: 20px;
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Sidebar del single
   ============================================================ */

.comercio-sidebar {
    background: var(--surface);
    border: 1px solid var(--rule);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: var(--shadow-sm);
    height: fit-content;
}

.comercio-img {
    border-radius: var(--radius-sm);
    overflow: hidden;
    margin-bottom: 20px;
    aspect-ratio: 1 / 1;
    background: var(--surface);
}

.comercio-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: var(--radius-sm);
}

.comercio-sidebar p {
    margin: 12px 0;
    font-size: 15px;
    line-height: 1.5;
    color: var(--ink-2);
}

.comercio-direccion {
    background: var(--surface-2);
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    color: var(--ink) !important;
    border-left: 3px solid var(--clay);
    font-size: 16px;
}

.comercio-telefono a {
    color: var(--ink);
    font-weight: 600;
}

.comercio-telefono a:hover {
    color: var(--accent);
}

/* Botones grandes de contacto */
.comercio-whatsapp,
.comercio-instagram,
.comercio-web {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    justify-content: center;
    padding: 12px 16px;
    margin: 8px 0;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: all var(--t);
    border: 1px solid transparent;
    box-sizing: border-box;
}

.comercio-whatsapp {
    background: var(--accent);
    color: var(--accent-ink);
}

.comercio-whatsapp:hover {
    background: #2f5530;
    color: var(--accent-ink);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.comercio-instagram {
    background: var(--surface);
    color: var(--ink);
    border-color: var(--rule-strong);
}

.comercio-instagram:hover {
    border-color: var(--accent-2);
    color: var(--accent-2);
}

.comercio-web {
    background: var(--surface);
    color: var(--ink);
    border-color: var(--rule-strong);
}

.comercio-web:hover {
    border-color: var(--clay);
    color: var(--clay);
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Horario
   ============================================================ */

.comercio-horario-wrap {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px dashed var(--rule-strong);
}

.comercio-horario-wrap h3 {
    margin: 0 0 12px;
    font-family: var(--font-body);
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--ink-2);
    font-weight: 600;
}

.comercio-horario {
    list-style: none;
    padding: 0;
    margin: 0;
}

.comercio-horario li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 14px;
    color: var(--ink);
    border-bottom: 1px solid var(--rule);
}

.comercio-horario li:last-child {
    border-bottom: none;
}

.comercio-horario li strong {
    color: var(--ink-2);
    font-weight: 500;
}

.comercio-horario .cerrado {
    color: var(--accent-2);
    font-style: italic;
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Mapa (single + modal)
   ============================================================ */

.comercio-map {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--rule);
}

#comercio-map {
    border-radius: var(--radius) !important;
}

.comercio-map h2 {
    margin-bottom: 15px;
}

/* Modal del mapa (desde las cards) */
.map-modal {
    position: fixed;
    inset: 0;
    background: rgba(36, 20, 41, .55);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}

.map-modal-content {
    background: var(--surface);
    border-radius: var(--radius);
    max-width: 800px;
    width: 100%;
    padding: 20px;
    position: relative;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--rule);
    margin: 0;
}

.close-map {
    position: absolute;
    top: 10px;
    right: 14px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface-2);
    color: var(--ink);
    border-radius: 50%;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    transition: all var(--t);
    z-index: 10;
}

.close-map:hover {
    background: var(--accent-2);
    color: #fff;
}

#modal-map {
    border-radius: var(--radius-sm);
    overflow: hidden;
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — SEO / descripción
   ============================================================ */

.comercio-seo,
.descripcion-categoria,
#descripcion_corta {
    background: var(--surface);
    border: 1px solid var(--rule);
    border-radius: var(--radius);
    padding: 28px 32px;
    margin: 30px 0;
    line-height: 1.7;
    color: var(--ink);
}

.comercio-seo h2 {
    margin-top: 0;
    color: var(--accent);
    text-align: center;
    font-size: 1.4rem;
}

section.comercio-seo h2 {
    margin-top: 15px;
}

.comercio-content p,
.descripcion-categoria p {
    margin: 12px 0;
    color: var(--ink-2);
}

.descripcion-categoria h2 {
    margin-top: 30px;
}

#descripcion_corta div {
    margin-top: 25px;
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Galería
   ============================================================ */

.comercio-galeria {
    margin-top: 50px;
    padding: 0 15px;
}

.comercio-galeria h2 {
    text-align: center;
    margin-bottom: 25px;
    font-size: 1.6rem;
    color: var(--ink);
}

.galeria-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 25px;
}

.galeria-item {
    display: block;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: var(--radius);
    position: relative;
    box-shadow: var(--shadow-sm);
    transition: transform var(--t), box-shadow var(--t);
}

.galeria-item:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-md);
}

.galeria-img {
    width: 100%;
    height: 100%;
    max-height: 300px;
    object-fit: cover;
    display: block;
}

@media (hover: hover) {
    .galeria-img {
        transition: transform 0.3s ease;
    }

    .galeria-item:hover .galeria-img {
        transform: scale(1.07);
    }
}

/* ============================================================
   DIRECTORIO DE COMERCIOS — Volver a categoría
   ============================================================ */

.comercio-back {
    text-align: center;
    margin: 40px 0 20px;
    padding-top: 30px;
    border-top: 1px solid var(--rule);
}

.comercio-back a {
    display: inline-block;
    padding: 10px 22px;
    background: var(--surface-2);
    color: var(--ink);
    border-radius: var(--radius-pill);
    border: 1px solid var(--rule-strong);
    font-size: 14px;
    font-weight: 500;
    transition: all var(--t);
}

.comercio-back a:hover {
    background: var(--accent);
    color: var(--accent-ink);
    border-color: var(--accent);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

/* ============================================================
   SIDEBAR — Widget de categorías (theme)
   ============================================================ */

#sidebar .widget_presscore-blog-categories {
    background: var(--surface);
    border: 1px solid var(--rule);
    border-radius: var(--radius);
    padding: 28px 24px;
    box-shadow: var(--shadow-sm);
}

#sidebar .widget_presscore-blog-categories .widget-title {
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--ink);
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--rule);
}

#sidebar .custom-categories {
    list-style: none;
    margin: 0;
    padding: 0;
}

#sidebar .custom-categories .cat-item {
    margin: 0;
}

#sidebar .custom-categories .cat-item a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    text-decoration: none;
    transition: all var(--t);
}

#sidebar .custom-categories .cat-item a:hover {
    background: var(--surface-2);
}

#sidebar .custom-categories .cat-item a .item-name {
    color: var(--ink-2);
    font-size: 15px;
    font-weight: 500;
    transition: color var(--t);
}

#sidebar .custom-categories .cat-item a:hover .item-name {
    color: var(--ink);
}

#sidebar .custom-categories .cat-item a .item-num {
    background: var(--surface-2);
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: var(--radius-pill);
    transition: all var(--t);
}

#sidebar .custom-categories .cat-item a:hover .item-num {
    background: var(--ink);
    color: var(--bg);
}

#sidebar .custom-categories .cat-item.current-cat a .item-name {
    color: var(--accent);
    font-weight: 700;
}

#sidebar .custom-categories .cat-item.current-cat a .item-num {
    background: var(--accent);
    color: var(--accent-ink);
}

/* ============================================================
   Accesibilidad
   ============================================================ */

.comercio-single ::selection,
.grid-comercios ::selection {
    background: var(--clay);
    color: #fff;
}

.comercio-single a:focus-visible,
.grid-comercios a:focus-visible,
.buscador *:focus-visible,
.comercio-icons *:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-radius: 0;
}

.dc-campo-barrios {
    margin-bottom: 10px;
}

.buscador #dc-filtro-form input[type="text"], .buscador #dc-filtro-form select {
    width: 100%;
    box-sizing: border-box;
    height: 25px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

/* Tablet */
@media (max-width: 1024px) {
    .grid-comercios {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Móvil */
@media (max-width: 840px) {
    .comercio-layout {
        grid-template-columns: 1fr;
        gap: 24px;
        padding: 15px;
    }
}

@media (max-width: 768px) {
    .grid-comercios {
        grid-template-columns: 1fr;
    }

    .same-logo,
    .preload-me {
        width: 200px !important;
        height: auto !important;
    }

    .buscador {
        padding: 15px;
    }

    .buscador form {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .btn-buscar {
        width: 100%;
        justify-content: center;
        padding: 13px 20px;
        height: 70px;
    }

    .map-modal-content {
        max-width: 95%;
        padding: 15px;
    }

    .comercio-title {
        margin: 20px 0;
        font-size: 1.8rem;
    }

    .grid-comercios {
        margin-top: 30px;
        margin-bottom: 60px;
    }
}

@media (min-width: 768px) {
    .galeria-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 15px;
        margin-bottom: 25px;
    }
}

@media (min-width: 1200px) {
    .galeria-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Separador visual (heredado del theme) */
div[style*="border-top"] {
    margin-top: 60px !important;
    padding-top: 30px !important;
}

/* ==========================
   Buscador cabecera
   ========================== */
.buscador.buscador-header {
    background: transparent;
    padding: 0;
    margin: 0;
}

.buscador-header .dc-buscador-header-form {
    display: flex;
    align-items: stretch;
    background: #2d1f38;               /* fondo morado oscuro */
    border-radius: 0px;
    overflow: hidden;
    max-width: 900px;
    width: 100%;
    box-shadow: 0 2px 10px rgba(0,0,0,.15);
}

/* Cada campo */
.buscador-header .campo {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 10px 15px;
    min-width: 0;                      /* evita que el select desborde */
    position: relative;
}

/* Divisor sutil entre campos */
.buscador-header .campo + .campo {
    border-left: 1px solid rgba(255, 255, 255, 0.08);
}

/* Etiquetas pequeñas en mayúscula */
.buscador-header .campo label {
    display: block;
    font-size: 11px;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    color: #a89bb0;
    font-weight: 600;
    margin: 0 0 4px;
    line-height: 1;
}

/* Input y select "sin caja", integrados en el fondo */
.buscador-header input[type="text"],
.buscador-header select {
    background: transparent !important;
    border: 0 !important;
    outline: none !important;
    box-shadow: none !important;
    color: #ffffff;
    font-size: 16px;
    line-height: 1.4;
    padding: 0;
    margin: 0;
    width: 100%;
    height: auto;
    font-family: inherit;
}

.buscador-header input[type="text"]::placeholder {
    color: #d7cddf;
    opacity: 1;
}

/* Select con flecha custom */
.buscador-header select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    padding-right: 22px;
    cursor: pointer;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='%23d7cddf' d='M6 8 0 0h12z'/></svg>");
    background-repeat: no-repeat;
    background-position: right center;
}

/* Las opciones sí las pintamos en fondo claro por legibilidad */
.buscador-header select option {
    color: #222;
    background: #fff;
}

/* Botón verde */
.buscador-header .btn-buscar {
    background: #5aa64a;               /* verde de la maqueta */
    color: #ffffff;
    border: 0;
    padding: 0 42px;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: .3px;
    cursor: pointer;
    transition: background .2s ease;
    border-radius: 0;                  /* la esquina la da el overflow del form */
    display: flex;
    align-items: center;
    justify-content: center;
}

.buscador-header .btn-buscar:hover,
.buscador-header .btn-buscar:focus {
    background: #4c9440;
}

.buscador-header .btn-buscar i {
    display: none;                     /* solo texto en la cabecera */
}

/* Foco accesible */
.buscador-header input[type="text"]:focus,
.buscador-header select:focus {
    outline: none;
}
.buscador-header .campo:focus-within label {
    color: #ffffff;
}

/* ==========================
   Responsive
   ========================== */
@media (max-width: 720px) {
    .buscador-header .dc-buscador-header-form {
        flex-direction: column;
        border-radius: 0px;
    }
    .buscador-header .campo + .campo {
        border-left: 0;
        border-top: 1px solid rgba(255, 255, 255, 0.08);
    }
    .buscador-header .btn-buscar {
        padding: 16px;
        width: 100%;
    }
}

.dc-buscador-header-form input, .dc-buscador-header-form select {
    margin-bottom: 0px !important;
}

/* Padres en negrita, hijos con color un poco más suave */
.buscador-header select option.level-0 {
    font-weight: 700;
    color: #222;
}
.buscador-header select option.level-1 {
    font-weight: 400;
    color: #555;
    padding-left: 12px; /* Chrome lo respeta */
}
.buscador-header select option.level-2 {
    padding-left: 24px;
}

.footer .widget-title {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: color-mix(in oklab, var(--bg) 55%, transparent);
    font-weight: 500;
    margin: 0 0 20px; 
}

/* ========================================
   Contact Form 7 — estilos Paterna.info
   ======================================== */

.cf7-paterna .cf7-campo,
.cf7-paterna .cf7-check,
.cf7-paterna .cf7-submit {
  margin: 0 0 20px;
  padding: 0;
}

.cf7-paterna label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
  font-size: 13px;
  color: var(--ink);
  letter-spacing: 0.01em;
}

.cf7-paterna .req {
  color: var(--accent-2);
}

.cf7-paterna .ayuda-inline {
  font-weight: 400;
  color: var(--muted);
  font-size: 12px;
  margin-left: 4px;
}

.cf7-paterna .ayuda {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-top: 6px;
  line-height: 1.5;
}

/* Inputs y textarea — solo elementos de formulario reales, no los spans wrapper de CF7 */
.cf7-paterna input.wpcf7-form-control:not([type="submit"]):not([type="checkbox"]):not([type="radio"]),
.cf7-paterna textarea.wpcf7-form-control,
.cf7-paterna select.wpcf7-form-control {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--rule-strong);
  border-radius: 4px;
  background: var(--bg);
  color: var(--ink);
  font-size: 15px;
  font-family: inherit;
  box-sizing: border-box;
  transition: border-color .18s;
}

/* Checkbox de aceptación: aseguramos que el wrapper NO tenga caja */
.cf7-paterna .cf7-check .wpcf7-form-control-wrap,
.cf7-paterna .cf7-check .wpcf7-acceptance {
  display: inline;
  padding: 0;
  border: 0;
  background: transparent;
  width: auto;
}

.cf7-paterna .cf7-check input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
  cursor: pointer;
}

input.wpcf7-form-control.wpcf7-submit.has-spinner:hover {
    background: var(--accent) !important;
    color: var(--surface) !important; 
}

.cf7-paterna input.wpcf7-form-control:not([type="submit"]):not([type="checkbox"]):not([type="radio"]):focus,
.cf7-paterna textarea.wpcf7-form-control:focus,
.cf7-paterna select.wpcf7-form-control:focus {
  outline: none;
  border-color: var(--accent);
}

.cf7-paterna .wpcf7-form-control:not([type="submit"]):focus {
  outline: none;
  border-color: var(--accent);
}

.cf7-paterna textarea {
  min-height: 140px;
  resize: vertical;
  line-height: 1.55;
}

/* Select */
.cf7-paterna select.wpcf7-form-control {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none' stroke='%235A4A5F' stroke-width='1.5'><path d='M1 1l5 5 5-5'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
}

/* Checkbox de aceptación */
.cf7-paterna .cf7-check {
  padding: 14px 16px;
  background: var(--surface-2);
  border-radius: 4px;
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.5;
}

.cf7-paterna .cf7-check .wpcf7-list-item {
  margin: 0;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.cf7-paterna .cf7-check .wpcf7-list-item-label {
  cursor: pointer;
}

.cf7-paterna .cf7-check input[type="checkbox"] {
  margin-top: 3px;
  flex-shrink: 0;
}

.cf7-paterna .cf7-check a {
  color: var(--accent);
  border-bottom: 1px solid;
}

/* Botón enviar */
.cf7-paterna .wpcf7-submit {
  padding: 14px 26px;
  font-size: 15px;
  font-weight: 500;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  background: var(--accent);
  color: var(--accent-ink);
  transition: transform .18s;
  font-family: inherit;
  letter-spacing: 0.01em;
}

.cf7-paterna .wpcf7-submit:hover {
  transform: translateY(-1px);
}

/* Mensajes de respuesta de CF7 */
.wpcf7-response-output {
  margin: 20px 0 0 !important;
  padding: 14px 16px !important;
  border-radius: 4px !important;
  font-size: 14px;
  font-family: inherit;
}

.wpcf7 form.sent .wpcf7-response-output {
  background: #00bd3a;
  border: 1px solid #bbf7d0 !important;
  color: #166534;
}

.wpcf7 form.invalid .wpcf7-response-output,
.wpcf7 form.failed .wpcf7-response-output {
  background: #fef2f2;
  border: 1px solid #fecaca !important;
  color: #991b1b;
}

/* Errores por campo */
.wpcf7-not-valid-tip {
  font-size: 12px;
  color: #991b1b;
  margin-top: 4px;
}

/* Loading spinner del botón */
.wpcf7-spinner {
  background-color: var(--accent) !important;
}

.dc-cat-section {
    padding: 30px 0;
    background: var(--bg);
    color: var(--ink);
}
.dc-cat-wrap {
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
}

.dc-cat-head {
    display: grid;
    gap: 14px;
    max-width: 720px;
    margin-bottom: 44px;
}
.dc-cat-eyebrow {
    font-family: "JetBrains Mono", ui-monospace, monospace;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--accent);
}
.dc-cat-title {
    font-family: var(--font-title, "Cormorant Garamond", Georgia, serif);
    font-size: clamp(2rem, 3.8vw, 3rem);
    font-weight: 400;
    line-height: 1.05;
    letter-spacing: -0.01em;
    margin: 0;
    color: var(--ink);
}
.dc-cat-title em {
    font-style: italic;
    color: var(--accent);
}
.dc-cat-sub {
    color: var(--ink-2);
    max-width: 60ch;
    margin: 0;
    line-height: 1.55;
}

.dc-cat-grid {
    display: grid;
    grid-template-columns: repeat(var(--dc-cols, 4), 1fr);
}
.dc-cat-card {
    padding: 28px 24px;
    border: 1px solid var(--rule);
    margin: 5px;
    display: grid;
    border-radius: 5px;
    gap: 14px;
    align-content: start;
    background: var(--bg);
    transition: background .2s ease;
    position: relative;
    text-decoration: none;
    color: inherit;
    min-height: 150px;
}
.dc-cat-card:hover {
    background: var(--surface-2);
    color: inherit;
}
.dc-cat-card .cat-icon {
    width: 34px;
    height: 34px;
    color: var(--ink);
    transition: color .2s;
    margin: 0 auto;
}
.dc-cat-card:hover .cat-icon {
    color: var(--accent);
}
.dc-cat-card h3 {
    font-family: var(--font-body, -apple-system, "Segoe UI", sans-serif);
    font-size: 15px;
    font-weight: 600;
    line-height: 1.25;
    color: var(--ink);
    margin: 0;
    text-align: center;
}
.dc-cat-count {
    font-family: "JetBrains Mono", ui-monospace, monospace;
    font-size: 11px;
    color: var(--muted);
    letter-spacing: 0.05em;
}
.dc-cat-arrow {
    position: absolute;
    top: 24px;
    right: 24px;
    color: var(--muted);
    opacity: 0;
    transform: translateX(-4px);
    transition: opacity .2s, transform .2s, color .2s;
}
.dc-cat-card:hover .dc-cat-arrow {
    opacity: 1;
    transform: translateX(0);
    color: var(--accent);
}

/* Responsive: 3 cols en tablet, 2 en móvil grande, 2 en móvil */
@media (max-width: 1024px) {
    .dc-cat-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 720px) {
    .dc-cat-grid { grid-template-columns: repeat(2, 1fr); }
    .dc-cat-card { padding: 22px 18px; min-height: 130px; }
    .dc-cat-card h3 { font-size: 14px; }
}
@media (max-width: 380px) {
    .dc-cat-grid { grid-template-columns: 1fr; }
}

.wf-container-main h1 {
    font-family: "Instrument Serif", Georgia, "Times New Roman", serif;
    font-size: 55px;
    font-weight: 400;   /* Instrument Serif solo existe en 400; 500 no carga y el navegador finge negrita */
    line-height: 1.1em;
}

/* Dropdown de autocompletado */
.dc-alta-sugerencias {
    position: absolute;
    top: calc(100% + 2px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 6px;
    max-height: 260px;
    overflow-y: auto;
    box-shadow: 0 4px 12px rgba(0,0,0,.08);
    z-index: 50;
}
.dc-alta-sugerencias[hidden] { display: none; }
.dc-alta-sugerencias .item {
    padding: 10px 14px;
    cursor: pointer;
    font-size: 14px;
    line-height: 1.4;
    border-bottom: 1px solid #f0f0f0;
    color: #241429;
}
.dc-alta-sugerencias .item:last-child { border-bottom: 0; }
.dc-alta-sugerencias .item:hover,
.dc-alta-sugerencias .item.is-active {
    background: #f7f3ea;
    color: #3D6B3A;
}
.dc-alta-sugerencias .item small {
    display: block;
    color: #888;
    font-size: 12px;
    margin-top: 2px;
}
.dc-alta-sugerencias .loading,
.dc-alta-sugerencias .empty {
    padding: 10px 14px;
    font-size: 13px;
    color: #888;
    font-style: italic;
}

button.pfg-simple__mapbtn.open-map {
    background: none;
    border: none;
}

/* Alineación del buscador: los 3 controles a la misma altura */
.buscador form {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 14px;
    align-items: end;   /* alinea la parte de abajo, contando los labels */
}

.buscador input[type="text"],
.buscador select,
.buscador .btn-buscar {
    box-sizing: border-box;
    line-height: 1;
}

.buscador .btn-buscar {
    padding: 0 22px;         /* al fijar height, el padding vertical estorba */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.busca {
    height: 41px;
    margin-bottom: 9px;
}

/* El div contenedor del botón no debe empujar */
.buscador .dc-btn-wrap {
    margin: 0;
    display: flex;
    align-items: stretch;
}

/* En móvil, el buscador pasa a una columna y el botón se estira */
@media (max-width: 768px) {
    .buscador form {
        grid-template-columns: 1fr;
    }
    .buscador .dc-btn-wrap .btn-buscar {
        width: 100%;
    }
}