/* 1. Ocultar Elementos del Tema para evitar distracciones */
header, nav, #masthead, .site-header, .main-header, .elementor-location-header, .ast-main-header-wrap, #main-header, .et_fixed_nav #main-header, .fusion-header-wrapper,
.main-navigation, #site-navigation, .primary-menu, .menu-primary-container, .top-bar,
footer, #colophon, .site-footer, .main-footer, #footer, .footer, .elementor-location-footer, .fusion-footer, .et-l--footer, .site-info, .copyright, #footer-widgets,
#secondary, #sidebar, .widget-area, .sidebar,
/* NUEVO: Ocultar títulos de página comunes */
.entry-title, .page-title, .post-title, h1.entry-title, .ast-archive-description {
    display: none !important;
}

/* Forzar que el contenido de WordPress no limite el ancho */
.site-content, #content, .page-content, .entry-content, .ast-container, .container {
    margin: 0 !important;
    padding: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    border: none !important;
}

body { background: #fff !important; overflow-x: hidden; }

/* 2. Estilos Plugin - REVISADO PARA ANCHO COMPLETO */
.wpcitas-wrapper {
    font-family: 'Raleway', sans-serif;
    /*
     * ⭐ COLOR Y FONDO DECLARADOS, no heredados (14-sep-2026). Con un tema de BLOQUES, su hoja
     *    global mete en el body `background-color` y `color` sacados del theme.json, y estas
     *    pantallas son del plugin entero: un tema oscuro pintaba el portal del paciente oscuro
     *    sin que nada fallara. Declarandolos aqui, el portal se ve igual con cualquier tema.
     *
     * ⚠️ Se midio antes de escribirlo, contra el html real de las dos pantallas: con el tema
     *    CLASICO --que es el de produccion-- esto cambia 1.729 pixeles de 1,4 millones, o sea
     *    nada. El TAMAÑO de letra se dejo fuera a proposito: fijarlo cambia 138.685 y eso ya no
     *    es blindar, es rediseñar el portal.
     */
    color: #333;
    background: #fff;
    /*
     * ⭐ Y EL TAMANO BASE, que tambien se heredaba. Twenty Twenty-One pone el body a 1.25rem
     *    --20px-- y el portal crecia con el; otro tema lo pondria a otra cosa. Lo que llevaba su
     *    tamano puesto por el plugin --el nombre del cliente, las cabeceras, los numeros, los
     *    botones-- no se movia; lo que heredaba, si, y por eso la linea de la zona horaria salia
     *    inflada.
     *
     * ⚠️ ESTO SE VE EN PRODUCCION, y se decidio a proposito (14-sep-2026) despues de comparar las
     *    dos versiones: esa linea sale algo mas pequena que antes. A cambio, el portal se ve igual
     *    con cualquier tema, que es de lo que iba F4b.
     */
    font-size: 16px;
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    box-sizing: border-box;
}

.wpcitas-wrapper .header-banner {
    width: 100%;
    max-width: 100%;
    height: auto;
    display: block;
    margin-bottom: 20px;
}

/* Contenedor interno para que el contenido no se pegue a los bordes en pantallas gigantes */
.wpcitas-section, .wpcitas-menu-container, .wpcitas-ajax-container-inner {
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

/* Selector (Flujo normal, alineado a la derecha debajo de la imagen) */
.wpcitas-menu-container { text-align: right; margin: 25px auto 15px auto; padding-right: 5%; box-sizing: border-box; }
.wpcitas-nav-select { padding: 12px 20px; border-radius: 8px; border: 2px solid #88f; font-weight: bold; font-family: 'Raleway', sans-serif; color: #55c; background: #fff; cursor: pointer; box-shadow: 0 4px 6px rgba(0,0,0,0.1); font-size: 1.1rem; }

.wpcitas-wrapper .calendar-nav-container { display: flex; justify-content: space-between; align-items: center; width: 98%; max-width: 1200px; margin: 0 auto 15px auto; }

/*
 * 🔴 EL COLOR DE ESTOS DOS BOTONES SE LO LLEVABA EL TEMA (14-sep-2026). Twenty Twenty-One trae
 *    `button:not(:hover):not(:active):not(.has-text-color) { background-color: … }`, que vale
 *    0,3,1 de especificidad y gana a `.wpcitas-wrapper .nav-btn`, que vale 0,2,0: SIGUIENTE salia
 *    negro y «Avisarme» tambien, en vez de los colores del plugin.
 *
 * ⭐ Se repite aqui la misma pareja de `:not()` para subir a 0,4,0 y ganar, en vez de tirar de
 *    `!important`: el hover del plugin sigue mandando en su estado, porque el selector del tema
 *    se excluye solo en :hover y :active.
 *
 * ⚠️ El boton ANTERIOR no se veia afectado, pero no por estar bien: cuando esta deshabilitado
 *    lleva su color en un `style=` en linea, y eso gana a todo. Era una casualidad, no un diseño.
 */
.wpcitas-wrapper .nav-btn:not(:hover):not(:active) { background: #eee; color: #333; }
.wpcitas-wrapper .btn-move:not(:hover):not(:active) { background: #55c; color: #fff; }

.wpcitas-wrapper .nav-btn { background: #eee; color: #333; border: none; padding: 15px; cursor: pointer; border-radius: 5px; font-weight: bold; font-size: 1rem; white-space: nowrap; text-decoration: none; display: inline-block; line-height: 1; transition: background 0.15s, color 0.15s; }
.wpcitas-wrapper .nav-btn:hover { background: #55c; color: #fff; }
.wpcitas-wrapper .month-label { font-size: 1.5rem; font-weight: bold; color: #333; text-align: center; flex-grow: 1; margin: 0 10px; }
.wpcitas-wrapper .btn-cancel { background: #d63638; color: #fff; border: none; padding: 10px; border-radius: 5px; cursor: pointer; font-size: 1rem; line-height: 1; transition: background .15s; }
.wpcitas-wrapper .btn-cancel:hover { background: #a82424; }
.wpcitas-wrapper .btn-move { background: #55c; color: #fff; border: none; padding: 10px; border-radius: 5px; cursor: pointer; font-size: 1rem; line-height: 1; transition: background .15s; }
.wpcitas-wrapper .btn-move:hover { background: #338; }
.wpcitas-wrapper .calendar-table { width: 100%; max-width: 1200px; margin: 0 auto 30px auto; border-collapse: separate; border-spacing: 5px; table-layout: fixed; border: none !important;}
.wpcitas-wrapper .calendar-head { padding: 15px 0; text-align: center; border-radius: 8px; font-weight: bold; background: #55c; color: #fff; }
.wpcitas-wrapper .calendar-day { padding: 20px 0; text-align: center; border-radius: 8px; cursor: pointer; background: #eee; font-size: 1.1rem; border: none !important;}
.wpcitas-wrapper .day-active { background: #55c; color: #fff; }
.wpcitas-wrapper .day-disabled { background: #ccc !important; color: #555; cursor: default; }
.wpcitas-wrapper .slot-btn { display: block; width: 40%; max-width: 300px; margin: 10px auto; padding: 20px; background: #55c; color: #fff; text-decoration: none; border-radius: 10px; font-size: 1.5rem; font-weight: bold; text-align: center; }
.wpcitas-wrapper .slot-online { background: #a838a8; }

/* Accesibilidad: el hueco pasó de <a> a <button> -> reset para conservar el aspecto */
.wpcitas-wrapper .slot-btn { border: 0; font-family: inherit; cursor: pointer; }
/* Foco visible por teclado (días de la rejilla, huecos, navegación de mes y selector) */
.wpcitas-wrapper .calendar-day:focus-visible,
.wpcitas-wrapper .slot-btn:focus-visible,
.wpcitas-wrapper .nav-btn:focus-visible,
.wpcitas-nav-select:focus-visible {
    outline: 3px solid #338;
    outline-offset: 2px;
}

/* Estilos Secciones */
.wpcitas-section { display: none; width: 100%; margin: 10px auto 30px auto; padding: 20px; background: #fff; box-sizing: border-box; }
.active-section { display: block; }
.data-table { width: 100%; border-collapse: collapse; margin-top: 20px; border-radius: 10px; overflow: hidden; box-shadow: 0 0 10px rgba(0,0,0,0.05); }
.data-table th { background: #55c; color: #fff; padding: 15px; text-align: left; }
.data-table td { padding: 15px; border: none; }

/* Aviso del profesional al paciente (users.mensaje_pagecitas), debajo de su nombre.
   Hereda del .notice que tenia el portal del tema --fondo rojo, centrado, redondeado--
   pero con sus propios colores: el portal dejo de depender del tema en la 1.8.93 y este
   recuadro no puede ser la excepcion. word-break para un mensaje con un enlace largo. */
.wpcitas-wrapper .gestionacitas-portal-aviso {
    width: 80%;
    margin: 0 auto 22px auto;
    padding: 14px 18px;
    box-sizing: border-box;
    text-align: center;
    border-radius: 10px;
    border: 2px solid #a33;
    background: #c55;
    color: #fff;
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.4;
    overflow-wrap: anywhere;
}
/* Notas que el profesional dirige al paciente (las pinta el add-on Pro en el portal).
   Colores propios, como el aviso de arriba: el portal no hereda del tema desde la 1.8.93. */
.wpcitas-wrapper .gestionacitas-portal-notas { width: 80%; margin: 0 auto 26px auto; box-sizing: border-box; text-align: left; }
.wpcitas-wrapper .gestionacitas-portal-notas h3 { color: #445; font-size: 1.2rem; font-weight: 700; margin: 0 0 10px 0; text-align: center; }
.wpcitas-wrapper .gestionacitas-portal-nota { background: #eef; border-left: 5px solid #55c; border-radius: 8px; padding: 12px 16px; margin-bottom: 10px; color: #333; overflow-wrap: anywhere; }
.wpcitas-wrapper .gestionacitas-portal-nota-fecha { color: #667; font-size: 0.85rem; margin-bottom: 4px; }
.wpcitas-wrapper .gestionacitas-portal-nota-texto { font-size: 1rem; line-height: 1.45; }
/* El botón con el que el paciente cierra el mensaje. Discreto: la nota es lo que importa,
   y cerrar no se deshace, así que no conviene que invite a pulsarlo sin leer. */
.wpcitas-wrapper .gestionacitas-portal-nota-cerrar { margin-top: 10px; background: #fff; color: #55c; border: 1px solid #99a; border-radius: 6px; padding: 7px 14px; font-size: 0.85rem; cursor: pointer; }
.wpcitas-wrapper .gestionacitas-portal-nota-cerrar:hover { background: #55c; color: #fff; border-color: #55c; }
.wpcitas-wrapper .gestionacitas-portal-nota-cerrar[disabled] { opacity: 0.5; cursor: default; }
@media (max-width: 600px) {
    /* Contenedor al borde de la pantalla */
    .wpcitas-wrapper { width: 95%; left: 2.5%; right: 0; margin-left: 0; margin-right: 0; }
    /* Sección al 98% para ganar espacio lateral */
    .wpcitas-section { width: 98%; padding: 10px 5px; }
    .wpcitas-menu-container { text-align: center; padding-right: 0; margin-bottom: 20px; }
    .wpcitas-wrapper .month-label { font-size: 1rem; }
    .wpcitas-wrapper .nav-btn { padding: 10px; font-size: 0.8rem; border: none; }
    /* CALENDARIO: Reducimos espacio entre celdas para que los días crezcan */
    .wpcitas-wrapper .calendar-table { width: 100%; border-spacing: 2px; border: none; }
    /* DÍAS: Sin bordes y más grandes */
    .wpcitas-wrapper .calendar-day { padding: 15px 0; font-size: 1rem; border: none; }
    /* BOTONES DE HORA: Al 95% de ancho y sin bordes */
    .wpcitas-wrapper .slot-btn { width: 88%; font-size: 1.3rem; border: none; box-shadow: 0 4px 6px rgba(0,0,0,0.1); /* Sombra suave en lugar de borde */}
    /* SELECTOR: Sin borde */
    .wpcitas-nav-select { width: 100%; font-size: 1rem; border: none; box-shadow: 0 2px 5px rgba(0,0,0,0.1); }
    /* El aviso al paciente, casi a ancho completo y una pizca menor */
    .wpcitas-wrapper .gestionacitas-portal-aviso { width: 94%; font-size: 1rem; padding: 12px 14px; }
    /* Y las notas dirigidas, igual: en el movil el portal se lee casi a borde */
    .wpcitas-wrapper .gestionacitas-portal-notas { width: 94%; }
}
