:root {
    --navy: #092c55;
    --blue: #0868b5;
    --lime: #d8ee25;
    --orange: #ff7a00;
    --pink: #ed1461;
    --paper: #f6f8fb;
    --ink: #13243a;
    --muted: #617085;
    --line: #dce4ed;
    --white: #fff;
}

* {
    box-sizing: border-box;
}

html {
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
        "Segoe UI", sans-serif;
    color: var(--ink);
    background: var(--paper);
}

body {
    margin: 0;
}

/* CABECERA */

.topbar {
    min-height: 88px;
    padding: 0 clamp(20px, 5vw, 78px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    background: #fff;
    border-bottom: 4px solid var(--lime);
    position: sticky;
    top: 0;
    z-index: 20;
}

.brand {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    color: var(--navy);
    min-width: 0;
}

.brand-logo {
    width: 78px;
    height: 78px;
    object-fit: cover;
    object-position: center;
    border-radius: 14px;
    box-shadow: 0 8px 22px rgba(9, 44, 85, 0.16);
    border: 1px solid rgba(9, 44, 85, 0.08);
    background: #fff;
    flex: 0 0 78px;
}

.brand-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.brand small {
    color: var(--muted);
}

.brand strong {
    display: block;
    line-height: 1.05;
}

@media (max-width: 640px) {
    .brand-logo {
        width: 56px;
        height: 56px;
        flex-basis: 56px;
        border-radius: 12px;
    }

    .brand-text strong {
        font-size: 0.98rem;
    }

    .brand-text small {
        font-size: 0.78rem;
    }
}

nav {
    display: flex;
    align-items: center;
    gap: 20px;
}

nav a {
    color: var(--navy);
    font-weight: 750;
    text-decoration: none;
}

nav a:hover {
    color: var(--blue);
}

/* CONTENIDO PRINCIPAL */

main {
    max-width: 1220px;
    margin: auto;
    padding: 42px 24px 60px;
}

/* PORTADA */

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
    align-items: center;
    gap: 34px;
    min-height: 560px;
    background: linear-gradient(
        120deg,
        var(--navy),
        #064b84 62%,
        var(--blue)
    );
    border-radius: 28px;
    padding: clamp(30px, 5vw, 65px);
    color: #fff;
    position: relative;
    overflow: hidden;
}

.hero::before,
.hero::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    filter: blur(1px);
    opacity: 0.35;
}

.hero::before {
    width: 280px;
    height: 280px;
    background: var(--pink);
    right: -100px;
    top: -140px;
}

.hero::after {
    width: 180px;
    height: 180px;
    background: var(--orange);
    left: -90px;
    bottom: -120px;
}

.hero-copy,
.mascot-card {
    position: relative;
    z-index: 1;
}

.eyebrow {
    font-weight: 900;
    letter-spacing: 0.12em;
    color: var(--lime);
}

h1 {
    font-size: clamp(2.1rem, 5vw, 4.7rem);
    line-height: 0.98;
    margin: 18px 0 22px;
    max-width: 850px;
}

h1 em {
    font-style: normal;
    color: var(--lime);
}

.hero p {
    font-size: 1.17rem;
    line-height: 1.6;
    max-width: 760px;
}

.facts {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 28px;
}

.facts span {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.22);
    padding: 10px 13px;
    border-radius: 999px;
    font-weight: 750;
}

/* TARJETA DE IXATXO */

.mascot-card {
    width: 100%;
    max-width: 410px;
    justify-self: center;
    align-self: center;
    text-align: center;
    background: #fff;
    color: var(--ink);
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.22);
    overflow: hidden;
}

/*
   Contenedor de la imagen real de Ixatxo.
   Estas reglas se aplican también en ordenador.
*/

.hero-ixatxo {
    width: 100%;
    min-height: 300px;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    margin: 0 auto 14px;
    overflow: hidden;
}

.hero-ixatxo img {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 360px;
    object-fit: contain;
    object-position: center bottom;
    transition: transform 0.25s ease;
}

.hero-ixatxo img:hover {
    transform: scale(1.025);
}

/*
   Por si la imagen está puesta directamente dentro de .mascot-card
   sin el contenedor .hero-ixatxo.
*/

.mascot-card > img {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 360px;
    object-fit: contain;
    margin: 0 auto 14px;
}

/*
   Mascota provisional circular.
   Se mantiene por compatibilidad, aunque puedes eliminarla
   si ya utilizas la imagen real.
*/

.mascot {
    width: 180px;
    height: 180px;
    margin: auto;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 4.5rem;
    font-weight: 1000;
    color: var(--navy);
    background: radial-gradient(
        circle at 35% 28%,
        #fff 0 8%,
        var(--lime) 9% 34%,
        var(--orange) 35% 52%,
        var(--pink) 53% 70%,
        var(--blue) 71%
    );
    border: 8px solid #fff;
    box-shadow: 0 10px 30px rgba(9, 44, 85, 0.25);
}

.mascot-card p {
    font-size: 0.95rem;
    line-height: 1.4;
}

.mascot-card code {
    font-size: 0.8rem;
}

/* ASISTENTE */

.assistant {
    margin: 32px auto 0;
    max-width: 900px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 25px;
    box-shadow: 0 18px 45px rgba(23, 49, 80, 0.1);
    overflow: hidden;
}

.assistant-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    border-bottom: 1px solid var(--line);
}

.assistant-head > div:first-child {
    display: grid;
    grid-template-columns: 12px auto;
    column-gap: 10px;
}

.assistant-head small {
    grid-column: 2;
    color: var(--muted);
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #22ad65;
    margin-top: 6px;
    box-shadow: 0 0 0 4px #e4f8ec;
}

.lang-switch {
    display: flex;
    background: var(--paper);
    padding: 3px;
    border-radius: 10px;
}

.lang-switch button {
    border: 0;
    background: transparent;
    padding: 7px 10px;
    font-weight: 800;
    cursor: pointer;
    border-radius: 8px;
}

.lang-switch .active {
    background: var(--navy);
    color: #fff;
}

.chips {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 15px 20px;
    border-bottom: 1px solid var(--line);
    scrollbar-width: thin;
}

.chips button {
    white-space: nowrap;
    border: 1px solid #cbd9e8;
    background: #f7fbff;
    color: var(--navy);
    font-weight: 750;
    padding: 9px 12px;
    border-radius: 999px;
    cursor: pointer;
}

.chips button:hover {
    background: #e9f4ff;
}

.messages {
    height: 365px;
    overflow-y: auto;
    padding: 24px;
    background: linear-gradient(#fff, #fbfdff);
}

.message {
    display: flex;
    gap: 10px;
    margin-bottom: 18px;
    max-width: 84%;
}

.message p {
    margin: 4px 0 0;
    line-height: 1.55;
}

.message.bot > div:last-child {
    background: #eef6ff;
    padding: 13px 16px;
    border-radius: 5px 18px 18px 18px;
}

.message.user {
    margin-left: auto;
    justify-content: flex-end;
}

.message.user > div {
    background: var(--navy);
    color: #fff;
    padding: 12px 16px;
    border-radius: 18px 5px 18px 18px;
}

.avatar {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--lime);
    color: var(--navy);
    font-weight: 950;
    flex: 0 0 36px;
}

.answer-link {
    display: inline-block;
    margin-top: 10px;
    color: var(--blue);
    font-weight: 800;
}

#chat-form {
    display: flex;
    gap: 10px;
    padding: 16px 18px;
    border-top: 1px solid var(--line);
}

input {
    width: 100%;
    border: 1px solid #bccbda;
    border-radius: 12px;
    padding: 13px 15px;
    font: inherit;
}

input:focus {
    outline: 3px solid rgba(8, 104, 181, 0.15);
    border-color: var(--blue);
}

button {
    font: inherit;
}

#chat-form button,
.login-card button,
.save-button {
    border: 0;
    border-radius: 12px;
    background: var(--orange);
    color: #fff;
    font-weight: 900;
    padding: 12px 20px;
    cursor: pointer;
}

#chat-form button:hover,
.login-card button:hover,
.save-button:hover {
    filter: brightness(0.95);
}

.notice {
    font-size: 0.84rem;
    color: #7a5a00;
    background: #fff8d7;
    margin: 0;
    padding: 10px 20px;
    text-align: center;
}

/* PIE */

footer {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    background: var(--navy);
    color: #fff;
    padding: 24px clamp(20px, 5vw, 78px);
}

footer a {
    color: var(--lime);
    font-weight: 800;
}

.sr-only {
    position: absolute;
    left: -9999px;
}

/* ADMINISTRACIÓN */

.admin-body {
    background: #eef3f8;
    min-height: 100vh;
}

.login-card {
    width: min(430px, calc(100% - 30px));
    margin: 10vh auto;
    background: #fff;
    padding: 34px;
    border-radius: 22px;
    box-shadow: 0 20px 55px rgba(9, 44, 85, 0.16);
}

.login-card form {
    display: grid;
    gap: 16px;
    margin: 22px 0;
}

.login-card label,
.form-grid label {
    display: grid;
    gap: 7px;
    font-weight: 750;
}

.error {
    background: #ffe8e8;
    color: #9b1616;
    padding: 11px;
    border-radius: 10px;
}

.admin-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px clamp(20px, 4vw, 60px);
    background: var(--navy);
    color: #fff;
}

.admin-top h1 {
    font-size: 1.45rem;
    margin: 0;
}

.admin-top a {
    color: #fff;
}

.admin-panel {
    max-width: 1000px;
    padding-top: 30px;
}

.admin-panel section {
    background: #fff;
    border-radius: 18px;
    padding: 24px;
    margin-bottom: 22px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

.checkbox {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    font-weight: 800;
}

.checkbox input {
    width: auto;
}

.warning {
    background: #fff4cf;
    padding: 10px;
    border-radius: 9px;
}

.saved {
    background: #e2f8e9;
    color: #176638;
    padding: 12px 15px;
    border-radius: 10px;
    margin-bottom: 15px;
}

.save-button {
    font-size: 1rem;
}

.badge {
    padding: 5px 9px;
    border-radius: 999px;
    font-weight: 800;
}

.pending {
    background: #fff1c7;
    color: #765400;
}

.confirmed {
    background: #daf5e4;
    color: #176638;
}

dl {
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 12px;
}

dt {
    font-weight: 800;
}

/* TABLET */

@media (max-width: 900px) {
    .hero {
        grid-template-columns: 1fr 320px;
        gap: 24px;
    }

    h1 {
        font-size: clamp(2.4rem, 6vw, 4rem);
    }

    .hero-ixatxo img,
    .mascot-card > img {
        max-height: 310px;
    }
}

/* MÓVIL */

@media (max-width: 760px) {
    .topbar {
        min-height: auto;
        padding: 14px 18px;
    }

    .topbar nav {
        display: none;
    }

    main {
        padding: 22px 12px 40px;
    }

    .hero {
        grid-template-columns: 1fr;
        min-height: auto;
        padding: 28px 22px;
        border-radius: 20px;
    }

    h1 {
        font-size: clamp(2.5rem, 13vw, 4rem);
    }

    .mascot-card {
        max-width: 100%;
        display: block;
        text-align: center;
        padding: 18px;
    }

    .hero-ixatxo {
        min-height: 230px;
        margin-bottom: 10px;
    }

    .hero-ixatxo img,
    .mascot-card > img {
        width: auto;
        max-width: 100%;
        max-height: 280px;
    }

    .mascot {
        width: 92px;
        height: 92px;
        font-size: 2.2rem;
        margin: 0 auto 12px;
    }

    .assistant {
        border-radius: 18px;
    }

    .assistant-head {
        padding: 16px;
    }

    .messages {
        height: 410px;
        padding: 18px 14px;
    }

    .message {
        max-width: 94%;
    }

    #chat-form {
        padding: 12px;
    }

    #chat-form button {
        padding: 12px 15px;
    }

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

    .admin-top {
        align-items: flex-start;
        gap: 15px;
    }

    .admin-top nav {
        flex-direction: column;
        gap: 6px;
    }

    footer {
        flex-direction: column;
        gap: 6px;
    }

    dl {
        grid-template-columns: 1fr;
        gap: 5px;
    }
}

/* =========================================================
   IXATXO IA 1.1 · FONDO DEL EVENTO Y MASCOTAS EN EL CHAT
   ========================================================= */

body.public-page {
    min-height: 100vh;
    position: relative;
    isolation: isolate;
    background: #edf3f8;
}

body.public-page::before,
body.public-page::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
}

body.public-page::before {
    z-index: -2;
    background-image: url("../images/logo.png");
    background-position: center 18%;
    background-repeat: no-repeat;
    background-size: cover;
    opacity: 0.42;
    filter: saturate(0.9) contrast(0.95);
}

body.public-page::after {
    z-index: -1;
    background:
        linear-gradient(180deg, rgba(246, 248, 251, 0.80), rgba(246, 248, 251, 0.87) 44%, rgba(237, 243, 248, 0.82)),
        radial-gradient(circle at 50% 18%, rgba(255, 255, 255, 0.28), transparent 46%);
}

.public-page .topbar {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 7px 28px rgba(9, 44, 85, 0.08);
}

.public-page main {
    position: relative;
}

.public-page .hero {
    box-shadow: 0 28px 75px rgba(9, 44, 85, 0.22);
}

.fact-button {
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.13);
    color: #fff;
    padding: 10px 14px;
    border-radius: 999px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.08);
    transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.fact-button:hover,
.fact-button:focus-visible {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.22);
    border-color: rgba(255, 255, 255, 0.55);
}

.fact-button:focus-visible,
.chips button:focus-visible,
.lang-switch button:focus-visible,
#chat-form button:focus-visible {
    outline: 3px solid rgba(216, 238, 37, 0.7);
    outline-offset: 3px;
}

.public-page .mascot-card {
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.public-page .assistant {
    position: relative;
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(188, 203, 218, 0.78);
    box-shadow: 0 25px 70px rgba(9, 44, 85, 0.18);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.assistant-head > .assistant-identity {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.assistant-head-avatar {
    width: 56px;
    height: 56px;
    display: grid;
    place-items: center;
    flex: 0 0 56px;
    overflow: hidden;
    border-radius: 18px;
    background: linear-gradient(145deg, #eff7ff, #fff8de);
    border: 1px solid #d9e6f1;
    box-shadow: 0 8px 18px rgba(9, 44, 85, 0.12);
}

.assistant-head-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center bottom;
    padding: 3px 5px 0;
}

.assistant-identity .status-dot {
    align-self: flex-start;
    margin: 7px 0 0 -17px;
    z-index: 2;
    border: 2px solid #fff;
}

.assistant-title {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.assistant-title strong {
    color: var(--navy);
    font-size: 1.05rem;
}

.assistant-title small {
    grid-column: auto;
    color: var(--muted);
}

.messages {
    height: min(52vh, 470px);
    min-height: 365px;
    scroll-behavior: smooth;
    background:
        linear-gradient(rgba(255, 255, 255, 0.94), rgba(250, 253, 255, 0.97)),
        url("../images/logo.png") center / 420px auto no-repeat;
}

.message {
    align-items: flex-end;
    gap: 12px;
}

.message .avatar {
    width: 54px;
    height: 62px;
    flex: 0 0 54px;
    overflow: hidden;
    border-radius: 18px 18px 10px 18px;
    background: linear-gradient(145deg, #edf7ff, #fff9da);
    border: 1px solid #d9e6f1;
    box-shadow: 0 8px 18px rgba(9, 44, 85, 0.11);
}

.message .avatar img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    object-position: center bottom;
    padding: 3px 4px 0;
}

.message .message-bubble {
    min-width: 0;
}

.message.bot > .message-bubble {
    position: relative;
    background: #eef6ff;
    padding: 13px 16px;
    border: 1px solid #dceaf7;
    border-radius: 6px 18px 18px 18px;
    box-shadow: 0 6px 18px rgba(9, 44, 85, 0.06);
}

.message.user > .message-bubble {
    background: var(--navy);
    color: #fff;
    padding: 12px 16px;
    border-radius: 18px 6px 18px 18px;
    box-shadow: 0 7px 18px rgba(9, 44, 85, 0.15);
}

.message.is-typing .message-bubble {
    min-width: 190px;
}

.typing-row {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 7px;
    color: var(--muted);
    font-size: 0.86rem;
}

.typing-row span {
    margin-right: 3px;
}

.typing-row i {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--blue);
    animation: ixatxoTyping 1.05s infinite ease-in-out;
}

.typing-row i:nth-child(3) {
    animation-delay: 0.14s;
}

.typing-row i:nth-child(4) {
    animation-delay: 0.28s;
}

@keyframes ixatxoTyping {
    0%, 60%, 100% { transform: translateY(0); opacity: 0.42; }
    30% { transform: translateY(-5px); opacity: 1; }
}

#chat-form.is-busy {
    opacity: 0.78;
}

#chat-form button:disabled,
#chat-form input:disabled {
    cursor: wait;
}

#chat-form button:disabled {
    filter: grayscale(0.2);
}

@media (max-width: 760px) {
    body.public-page::before {
        background-position: center top;
        background-size: auto 100vh;
        opacity: 0.34;
    }

    .assistant-head-avatar {
        width: 48px;
        height: 48px;
        flex-basis: 48px;
        border-radius: 15px;
    }

    .assistant-identity .status-dot {
        margin-left: -16px;
    }

    .assistant-title small {
        max-width: 170px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .messages {
        height: 58vh;
        min-height: 390px;
        background-size: 320px auto;
    }

    .message .avatar {
        width: 46px;
        height: 54px;
        flex-basis: 46px;
        border-radius: 15px 15px 8px 15px;
    }

    .message {
        gap: 8px;
    }

    .message.bot {
        max-width: 98%;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
/* Ixatxo integrado dentro de WordPress */
body.embed-mode {
  background: #fff;
}

body.embed-mode header,
body.embed-mode .hero,
body.embed-mode .hero-section,
body.embed-mode .welcome-section,
body.embed-mode .intro-section,
body.embed-mode footer {
  display: none !important;
}

body.embed-mode main {
  padding-top: 0 !important;
  margin-top: 0 !important;
}

body.embed-mode .chat-section,
body.embed-mode .chat-container,
body.embed-mode #chat {
  margin-top: 0 !important;
  padding-top: 12px !important;
  min-height: calc(100vh - 24px);
}

/* Participaciones con diploma y fotos dentro del chat */
.runner-result-card {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #cbdced;
  border-radius: 16px;
  background: rgba(255,255,255,.82);
}
.runner-card-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.runner-card-head strong {
  font-size: 20px;
  color: #092c55;
}
.runner-card-head span {
  color: #52677f;
  font-weight: 700;
}
.runner-photo-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 10px 0 12px;
}
.runner-photo-thumb {
  display: block;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 10px;
  background: #eaf1f8;
}
.runner-photo-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .2s ease;
}
.runner-photo-thumb:hover img { transform: scale(1.04); }
.runner-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.runner-card-action {
  display: inline-flex;
  align-items: center;
  padding: 9px 12px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid #bfd3e8;
  color: #0868b5 !important;
  font-weight: 800;
  text-decoration: none !important;
}
.runner-card-action.primary {
  background: #092c55;
  border-color: #092c55;
  color: #fff !important;
}
.runner-no-photos {
  margin: 8px 0 12px !important;
  color: #617085;
  font-size: 14px;
}

/* Páginas específicas para integrar el chat en WordPress */
.wordpress-chat-page {
  min-height: 100vh;
  margin: 0;
  background: #f6f8fb;
}
.wordpress-chat-shell {
  width: min(100%, 1180px);
  margin: 0 auto;
  padding: 16px;
  box-sizing: border-box;
}
.wordpress-chat-intro {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 12px;
  padding: 12px 16px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid #dce4ed;
}
.wordpress-chat-intro img {
  width: 64px;
  height: 64px;
  object-fit: contain;
}
.wordpress-chat-intro h1 {
  margin: 0 0 3px;
  font-size: clamp(22px, 3vw, 32px);
  color: #092c55;
}
.wordpress-chat-intro p { margin: 0; color: #617085; }
.wordpress-chat-page .assistant {
  margin: 0;
  min-height: calc(100vh - 130px);
}
.wordpress-chat-compact .wordpress-chat-shell { padding: 0; max-width: none; }
.wordpress-chat-compact .assistant {
  border-radius: 0;
  min-height: 100vh;
  box-shadow: none;
  border-left: 0;
  border-right: 0;
}
.wordpress-chat-compact .messages {
  min-height: calc(100vh - 285px);
}

@media (max-width: 700px) {
  .runner-photo-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .wordpress-chat-shell { padding: 0; }
  .wordpress-chat-intro { border-radius: 0; margin: 0; }
  .wordpress-chat-page .assistant { border-radius: 0; }
}


/* WordPress v1.5.1: chat compacto, controles visibles y sin scroll horizontal */
.wordpress-chat-page {
  overflow: hidden;
}

.wordpress-chat-page .assistant {
  height: 100vh;
  min-height: 620px;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto auto;
  overflow: hidden;
}

.wordpress-chat-page .assistant-head {
  min-height: 68px;
  padding: 8px 18px;
}

.wordpress-chat-page .assistant-title {
  line-height: 1.1;
}

.wordpress-chat-page .assistant-subtitle {
  display: block;
  white-space: normal;
  line-height: 1.15;
}

.wordpress-chat-page .wordpress-chips {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
  padding: 10px 14px;
  overflow: visible;
  box-sizing: border-box;
  border-bottom: 1px solid #dce4ed;
}

.wordpress-chat-page .wordpress-chips button {
  min-width: 0;
  width: 100%;
  padding: 10px 8px;
  font-size: 15px;
  line-height: 1.15;
  white-space: normal;
  text-align: center;
}

.wordpress-chat-page .messages {
  height: auto !important;
  min-height: 0 !important;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 18px 22px;
  scroll-behavior: smooth;
}

.wordpress-chat-page #chat-form {
  position: relative;
  z-index: 10;
  margin: 0;
  padding: 10px 14px;
  background: #fff;
  border-top: 1px solid #dce4ed;
  box-shadow: 0 -8px 18px rgba(9, 44, 85, .06);
}

.wordpress-chat-page .notice {
  margin: 0;
  padding: 5px 14px 8px;
  background: #fff;
  font-size: 12px;
  line-height: 1.25;
}

.wordpress-chat-compact .messages {
  min-height: 0 !important;
}

@media (max-width: 900px) {
  .wordpress-chat-page .wordpress-chips {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .wordpress-chat-page .assistant {
    min-height: 560px;
  }
  .wordpress-chat-page .assistant-head {
    padding: 7px 10px;
  }
  .wordpress-chat-page .wordpress-chips {
    gap: 6px;
    padding: 8px;
  }
  .wordpress-chat-page .wordpress-chips button {
    padding: 8px 5px;
    font-size: 13px;
  }
  .wordpress-chat-page .messages {
    padding: 12px 10px;
  }
  .wordpress-chat-page #chat-form {
    padding: 8px;
  }
  .wordpress-chat-page .notice {
    display: none;
  }
}
