/* Inter 4.1, SIL Open Font License; scoped to the Agent. */
@font-face { font-family: 'JMax Agent Inter'; src: url('../fonts/InterVariable.woff2') format('woff2'); font-style: normal; font-weight: 100 900; font-display: swap; }
:root { --jm-agent-accent: #e5493a; --jm-agent-accent-hover: #af2a1d; }
/* Native dialog stays in the top layer above the theme's high z-indices. */
.jm-agent-launcher { cursor: pointer; }
.jm-agent-launcher[hidden] { display: none !important; }
.jm-agent-launcher--floating { position: fixed; top: 16px; right: 16px; z-index: 2147483002; display: inline-flex; height: 56px; padding: 0 22px 3px; align-items: center; justify-content: center; gap: 11px; border: 0; border-radius: 8px; background: var(--jm-agent-accent); color: #fff; font: 300 22px/1 'Myriad', Tahoma, sans-serif; white-space: nowrap; transition: background-color .5s; }
.jm-agent-launcher--floating:hover { background: var(--jm-agent-accent-hover); }
.jm-agent-launcher--floating .jm-agent-star-icon { font-size: 27px; line-height: 1; }
.jm-agent-overlay { position: fixed; inset: 0; box-sizing: border-box; width: 84vw; max-width: 1600px; height: 86vh; height: 86dvh; min-height: min(650px, 94dvh); max-height: 950px; margin: auto; padding: 0; border: 1px solid #d8d9dc; border-radius: 28px; background: #fff; color: #202124; font: 16px/1.55 'JMax Agent Inter', Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; box-shadow: 0 32px 100px rgba(0,0,0,.28), 0 8px 30px rgba(0,0,0,.12); overflow: hidden; overscroll-behavior: contain; }
.jm-agent-overlay::backdrop { background: rgba(5, 5, 7, .68); backdrop-filter: blur(5px); }
.jm-agent-overlay [hidden] { display: none !important; }
.jm-agent-overlay * { box-sizing: border-box; }
.jm-agent-shell { display: flex; flex-direction: column; height: 100%; min-height: 0; }
.jm-agent-svg-defs { position: absolute; width: 0; height: 0; overflow: hidden; pointer-events: none; }
.jm-agent-header { display: grid; flex-shrink: 0; grid-template-columns: minmax(0, 7fr) minmax(260px, 3fr); min-height: 88px; padding: 0; border-bottom: 1px solid #e7e7e9; }
.jm-agent-header-brand { display: flex; width: 148px; min-width: 0; padding: 18px 0 17px 30px; flex-direction: column; box-sizing: content-box; }
.jm-agent-overlay .jm-agent-title { display: block; color: #202124; font: inherit; line-height: 1; margin: 0; }
.jm-agent-brand-logo { display: block; width: 148px; height: auto; }
.jm-agent-logo-accent { fill: var(--jm-agent-accent); }
.jm-agent-logo-main { fill: #202124; }
.jm-agent-subtitle { width: 100%; margin: 6px 0 0; color: #202124; text-align: right; white-space: nowrap; font-size: 19px; line-height: 1.2; font-weight: 500; letter-spacing: .01em; }
.jm-agent-header-side { display: flex; min-width: 0; padding: 18px 18px 17px 28px; align-items: center; gap: 14px; }
.jm-agent-offer-cta { min-height: 48px; padding: 0 18px; border: 1px solid #505050; border-radius: 16px; background: #505050; color: #fff; font: inherit; font-size: 15px; font-weight: 600; line-height: 1.2; transition: color 160ms ease, background 160ms ease, border-color 160ms ease; }
.jm-agent-offer-label { display: inline; }
.jm-agent-offer-tail { white-space: nowrap; }
.jm-agent-offer-cta:hover { border-color: var(--jm-agent-accent); background: var(--jm-agent-accent); color: #fff; }
.jm-agent-progress { display: flex; flex-shrink: 0; list-style: none; gap: 28px; padding: 0 28px; min-height: 44px; align-items: stretch; margin: 0; border-bottom: 1px solid #e7e7e9; font-size: 14px; }
.jm-agent-step { color: #96989e; margin: 0; padding: 12px 0 9px; line-height: 1.4; border-bottom: 2px solid transparent; }
.jm-agent-step[data-complete="true"] { color: #444449; }
.jm-agent-step[aria-current] { color: var(--jm-agent-accent); border-bottom-color: var(--jm-agent-accent); font-weight: 600; }
.jm-agent-feedback { flex-shrink: 0; width: 100%; min-width: 0; max-height: 32%; overflow-x: hidden; overflow-y: auto; padding: 12px 0 0; }
.jm-agent-status { margin: 0; color: #626269; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; }
.jm-agent-status:not(:empty) { padding: 10px 0; }
.jm-agent-feedback button { margin: 0 8px 10px 0; }
.jm-agent-layout { display: grid; grid-template-columns: minmax(0, 7fr) minmax(260px, 3fr); flex: 1; min-height: 0; overflow: hidden; }
.jm-agent-chat { min-width: 0; min-height: 0; display: flex; flex-direction: column; padding: 0 32px 20px; }
.jm-agent-feed { display: flex; flex-direction: column; gap: 24px; flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 30px 8px 26px 0; scrollbar-width: thin; }
.jm-agent-bubble { flex-shrink: 0; width: fit-content; max-width: min(78%, 760px); margin: 0; overflow-wrap: anywhere; animation: jm-agent-reveal 150ms ease-out; }
.jm-agent-message-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; color: #34353a; font-size: 13px; font-weight: 650; }
.jm-agent-avatar { display: block; width: 29px; height: 27px; flex: 0 0 auto; fill: var(--jm-agent-accent); overflow: visible; }
.jm-agent-message-text { margin: 0; padding: 14px 18px; border: 1px solid #ececef; border-radius: 28px; background: #f2f2f3; color: #28292d; white-space: pre-wrap; line-height: 1.55; box-shadow: 0 1px 2px rgba(20,20,22,.025); }
.jm-agent-bubble-user { align-self: flex-end; width: fit-content; max-width: 68%; }
.jm-agent-bubble-user .jm-agent-message-brand { justify-content: flex-end; font-size: 12px; color: #777980; font-weight: 500; margin-bottom: 6px; padding-right: 6px; }
.jm-agent-bubble-user .jm-agent-message-text { padding: 13px 18px; border: 1px solid var(--jm-agent-accent); border-radius: 28px; background: var(--jm-agent-accent); color: #fff; box-shadow: 0 5px 16px rgba(229,73,58,.14); }
.jm-agent-composer { flex-shrink: 0; margin: 0; }
.jm-agent-input-wrap { display: flex; gap: 14px; align-items: flex-end; min-height: 80px; border: 1px solid #dedfe2; border-radius: 24px; padding: 13px 14px 13px 18px; background: #fff; box-shadow: 0 3px 16px rgba(32,33,36,.035); transition: border-color 160ms ease, box-shadow 160ms ease; }
.jm-agent-input-wrap:focus-within { border-color: #bfc1c6; box-shadow: 0 4px 18px rgba(32,33,36,.055); }
.jm-agent-overlay .jm-agent-message { display: block; flex: 1; width: 100%; min-width: 0; min-height: 52px; height: 52px; max-height: 196px; overflow-y: auto; resize: none; padding: 4px 2px; margin: 0; border: 0; outline: 0; background: transparent; color: #202124; font: inherit; box-shadow: none; }
.jm-agent-overlay .jm-agent-message:focus, .jm-agent-overlay .jm-agent-message:focus-visible { outline: 0; box-shadow: none; }
.jm-agent-message::placeholder, .jm-agent-input::placeholder { color: #70737a; opacity: 1; }
.jm-agent-actions { display: flex; flex-shrink: 0; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; padding: 10px 4px 0; }
.jm-agent-hint, .jm-agent-privacy { font-size: 12px; color: #70737a; }
.jm-agent-overlay button { font: inherit; font-size: 15px; cursor: pointer; max-width: 100%; white-space: normal; }
.jm-agent-close, .jm-agent-handoff, .jm-agent-fallback, .jm-agent-back, .jm-agent-retry, .jm-agent-transcript, .jm-agent-result-ready { border: 0; border-radius: 10px; padding: 8px 10px; background: transparent; color: #55555d; }
.jm-agent-overlay .jm-agent-close { display: grid; place-items: center; margin-left: auto; flex-shrink: 0; width: 42px; height: 42px; padding: 0; border-radius: 50%; background: transparent; line-height: 1; }
.jm-agent-close-icon { position: relative; display: block; width: 18px; height: 18px; }
.jm-agent-close-icon span { position: absolute; top: 8px; left: -1px; width: 20px; height: 2px; border-radius: 999px; background: #54565c; transform-origin: center; transition: background 160ms ease; }
.jm-agent-close-icon span:first-child { transform: rotate(45deg); }
.jm-agent-close-icon span:last-child { transform: rotate(-45deg); }
.jm-agent-close:hover { background: transparent; }
.jm-agent-close:hover .jm-agent-close-icon span { background: var(--jm-agent-accent); }
.jm-agent-handoff { margin-left: -8px; }
.jm-agent-handoff:hover { background: transparent; color: var(--jm-agent-accent); }
.jm-agent-back:hover, .jm-agent-transcript:hover { background: #f0f0f2; color: #202124; }
.jm-agent-send, .jm-agent-submit-contact, .jm-agent-discuss, .jm-agent-done-close { border: 1px solid var(--jm-agent-accent); border-radius: 16px; padding: 12px 18px; background: var(--jm-agent-accent); color: #fff; transition: background 160ms ease, border-color 160ms ease, transform 160ms ease; }
.jm-agent-send:hover:not(:disabled), .jm-agent-submit-contact:hover:not(:disabled), .jm-agent-discuss:hover:not(:disabled), .jm-agent-done-close:hover:not(:disabled) { border-color: var(--jm-agent-accent-hover); background: var(--jm-agent-accent-hover); }
.jm-agent-overlay .jm-agent-send { position: relative; display: grid; place-items: center; flex-shrink: 0; width: 150px; height: 48px; border-radius: 24px; padding: 0 20px; font-size: 14px; font-weight: 650; }
.jm-agent-send-content { display: inline-flex; align-items: center; justify-content: center; gap: 9px; white-space: nowrap; }
.jm-agent-send-icon { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.jm-agent-send .jm-agent-loader { position: absolute; inset: 0; margin: auto; color: #fff; opacity: 0; }
.jm-agent-overlay[data-processing="true"] .jm-agent-send-content { visibility: hidden; }
.jm-agent-overlay[data-processing="true"] .jm-agent-send .jm-agent-loader { opacity: 1; }
.jm-agent-overlay[data-processing="true"] .jm-agent-send { opacity: .85; }
/* Reuse the theme forms' dot spinner and mulShdSpin keyframes. */
.jm-agent-overlay .jm-agent-loader { width: 2.5px; height: 2.5px; font-size: 2.5px; flex-shrink: 0; color: var(--jm-agent-accent); top: auto; left: auto; right: auto; margin: 10px; vertical-align: middle; z-index: auto; }
.jm-agent-overlay .jm-agent-send .jm-agent-loader { color: #fff; top: 0; left: 0; right: 0; margin: auto; }
.jm-agent-pending .jm-agent-message-text { display: inline-block; color: #666970; font-size: 14px; }
.jm-agent-pending > .jm-agent-loader { display: inline-block; margin-left: 10px; }
.jm-agent-inline-error .jm-agent-message-text { color: #70737a; }
.jm-agent-inline-actions { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 10px; }
.jm-agent-inline-actions button { border: 0; background: transparent; color: var(--jm-agent-accent); padding: 4px 0; font-size: 13px; text-align: left; }
.jm-agent-inline-actions button:hover { text-decoration: underline; }
.jm-agent-overlay :disabled { opacity: .5; cursor: default; }
.jm-agent-overlay :focus-visible, .jm-agent-launcher:focus-visible { outline: 3px solid var(--jm-agent-accent); outline-offset: 3px; }
.jm-agent-summary, .jm-agent-result-aside { min-width: 0; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 30px 28px; border-left: 1px solid #e4e5e7; background: #f8f8f9; }
.jm-agent-summary-title { margin: 0; color: #202124; font: inherit; font-size: 20px; line-height: 1.3; font-weight: 700; letter-spacing: -.015em; }
.jm-agent-summary-status { margin: 8px 0 28px; color: #777980; font-size: 13px; }
.jm-agent-summary-content, .jm-agent-result, .jm-agent-result-summary { overflow-wrap: anywhere; }
.jm-agent-summary-block { padding: 0 0 24px; animation: jm-agent-reveal 180ms ease-out; }
.jm-agent-heading { color: #202124; font: inherit; font-weight: 700; font-size: 19px; margin: 24px 0 8px; }
.jm-agent-summary-block .jm-agent-heading, .jm-agent-result-summary .jm-agent-heading { margin: 0 0 6px; font-size: 11px; color: #70737a; letter-spacing: .06em; text-transform: uppercase; font-weight: 600; }
.jm-agent-summary-block .jm-agent-copy { margin: 0; font-size: 15px; }
.jm-agent-copy, .jm-agent-empty { margin: 8px 0 16px; white-space: pre-wrap; }
.jm-agent-empty { color: #70737a; font-size: 15px; }
.jm-agent-list { padding-left: 22px; margin: 8px 0; }
.jm-agent-list li { margin: 5px 0; }
.jm-agent-view-title { color: #202124; font: inherit; font-size: clamp(24px, 2vw, 29px); font-weight: 700; line-height: 1.25; margin: 0 0 24px; }
.jm-agent-result-main { min-height: 0; min-width: 0; overflow-y: auto; overscroll-behavior: contain; padding: 32px; }
.jm-agent-result-aside > .jm-agent-heading { margin-top: 0; }
.jm-agent-result-aside button { display: block; width: 100%; min-height: 70px; margin-top: 16px; }
.jm-agent-result-summary .jm-agent-copy { font-size: 18px; }
.jm-agent-metrics { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 12px; margin-bottom: 28px; }
.jm-agent-metric { padding: 18px; border: 1px solid #e7e7e9; border-radius: 20px; background: #fff; }
.jm-agent-metrics .jm-agent-heading { font-size: 15px; font-weight: 600; color: #65676d; margin: 0; letter-spacing: -.01em; text-transform: none; }
.jm-agent-metrics .jm-agent-copy { margin: 10px 0 0; font-size: clamp(16px, 1.25vw, 18px); line-height: 1.42; font-weight: 600; }
.jm-agent-contact, .jm-agent-done { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 32px; }
.jm-agent-contact-inner { max-width: 520px; margin: auto; }
.jm-agent-eyebrow { font-size: 13px; color: var(--jm-agent-accent); margin: 0 0 10px; }
.jm-agent-label { display: block; color: #55555d; font-size: 14px; margin: 18px 0; }
.jm-agent-overlay .jm-agent-input { display: block; width: 100%; min-width: 0; height: auto; border: 1px solid #dedee3; border-radius: 14px; background: #fff; color: #202124; padding: 12px; font: inherit; margin-top: 6px; }
.jm-agent-link, .jm-agent-direct { color: #55555d; text-decoration: underline; }
.jm-agent-contact .jm-agent-submit-contact { width: 100%; }
.jm-agent-contact .jm-agent-back { display: block; margin: 12px auto 0; }
.jm-agent-done { display: flex; align-items: center; justify-content: center; }
.jm-agent-done-inner { width: 100%; max-width: 620px; margin-block: auto; text-align: center; }
.jm-agent-done-mark { display: inline-grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; color: var(--jm-agent-accent); background: #fbecee; font-size: 28px; margin-bottom: 24px; }
.jm-agent-done-message { font-size: 20px; white-space: pre-wrap; overflow-wrap: anywhere; }
.jm-agent-done .jm-agent-copy { color: #70737a; }
.jm-agent-done-close { margin-top: 16px; min-width: 150px; }
.jm-agent-captcha { width: 100%; min-width: 0; min-height: 100px; max-width: 100%; overflow: hidden; }
.jm-agent-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
@keyframes jm-agent-reveal { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }
@media (max-width: 1100px) {
    .jm-agent-overlay { width: 94vw; height: 92dvh; }
    .jm-agent-layout, .jm-agent-header { grid-template-columns: minmax(0, 7fr) minmax(230px, 3fr); }
    .jm-agent-close { margin-left: auto; }
}
@media (max-width: 700px) {
    .jm-agent-overlay { width: 100%; max-width: none; height: 100vh; height: 100dvh; min-height: 0; max-height: none; border: 0; border-radius: 0; font-size: 16px; }
    .jm-agent-shell { padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px); }
    .jm-agent-header { display: flex; min-height: 78px; padding: 13px 16px; align-items: center; gap: 10px; }
    .jm-agent-header-brand { width: 126px; padding: 0; box-sizing: border-box; }
    .jm-agent-brand-logo { width: 126px; }
    .jm-agent-progress { justify-content: space-between; gap: 8px; font-size: 11px; padding: 0 16px; }
    .jm-agent-feedback { padding-inline: 16px; }
    .jm-agent-chat-view { display: flex; flex-direction: column; }
    .jm-agent-chat { flex: 1; padding: 0 16px 12px; }
    .jm-agent-feed { gap: 22px; padding-top: 20px; }
    .jm-agent-summary { order: -1; flex-shrink: 0; max-height: 28%; border-left: 0; border-bottom: 1px solid #e7e7e9; padding: 12px 16px; }
    .jm-agent-summary-title { display: none; }
    .jm-agent-summary-toggle { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; border: 0; background: transparent; color: #202124; padding: 0; text-align: left; font-weight: 600; }
    .jm-agent-summary-toggle::after { content: '+'; color: #70737a; }
    .jm-agent-summary-toggle[aria-expanded="true"]::after { content: '−'; }
    .jm-agent-summary-body { padding-top: 10px; }
    .jm-agent-summary-status { margin-bottom: 12px; }
    .jm-agent-bubble { max-width: 92%; }
    .jm-agent-bubble-user { max-width: 88%; }
    .jm-agent-message-text, .jm-agent-bubble-user .jm-agent-message-text { border-radius: 24px; }
    .jm-agent-input-wrap { min-height: 74px; border-radius: 22px; padding: 11px 11px 11px 15px; }
    .jm-agent-overlay .jm-agent-send { width: 126px; height: 44px; border-radius: 22px; padding-inline: 14px; }
    .jm-agent-send-icon { width: 18px; height: 18px; }
    .jm-agent-actions { gap: 0; }
    .jm-agent-hint { font-size: 10px; }
    .jm-agent-result-view { display: block; overflow-y: auto; overscroll-behavior: contain; }
    .jm-agent-result-main { padding: 24px 16px; overflow: visible; }
    .jm-agent-result-aside { padding: 24px 16px; border-left: 0; border-top: 1px solid #e7e7e9; overflow: visible; }
    .jm-agent-metrics { grid-template-columns: minmax(0, 1fr); }
    .jm-agent-contact, .jm-agent-done { padding: 24px 16px; }
    .jm-agent-header-side { margin-left: auto; padding: 0; }
    .jm-agent-offer-cta { display: none; }
    .jm-agent-launcher--floating { top: 10px; right: 10px; }
}
@media (prefers-reduced-motion: reduce) {
    .jm-agent-overlay, .jm-agent-overlay *, .jm-agent-launcher { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}


/* JMax Agent entrypoints in the public site UI. */
.jm-agent-label-short { display: none; }
.jm-agent-star-icon { display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; color: currentColor; font-size: 28px; line-height: 1; }

.ap-bottom-fixed-menu .jm-site-agent-launcher {
    position: relative;
    z-index: 1;
    display: inline-flex;
    height: 70px;
    margin: 0 16px 0 0;
    padding: 0 36px 2px 32px;
    align-items: center;
    justify-content: center;
    gap: 13px;
    border: 0;
    border-radius: 8px;
    background: var(--jm-agent-accent);
    color: #fff;
    font: 300 27px/1 'Myriad', Tahoma, sans-serif;
    white-space: nowrap;
    transition: background-color .5s;
}
.ap-bottom-fixed-menu .jm-site-agent-launcher:hover { background: var(--jm-agent-accent-hover); }
.ap-bottom-fixed-menu .jm-site-agent-launcher .jm-agent-star-icon { font-size: 31.36px; }
.ap-bottom-fixed-menu .jm-site-agent-launcher {
    transition: background-color .5s, opacity .22s ease, transform .22s ease;
}

.jm-menu-agent-launcher {
    display: inline-flex;
    width: auto;
    min-height: 70px;
    margin: 0 0 34px;
    padding: 0 26px 2px 22px;
    align-self: flex-start;
    align-items: center;
    justify-content: center;
    gap: 14px;
    border: 0;
    border-radius: 8px;
    background: var(--jm-agent-accent);
    color: #fff;
    font: 300 25px/1.1 'Myriad', Tahoma, sans-serif;
    transition: background-color .5s;
}
.jm-menu-agent-launcher:hover { background: var(--jm-agent-accent-hover); }
.jm-menu-agent-launcher .jm-agent-star-icon { width: 31px; height: 31px; flex: 0 0 31px; fill: currentColor; }

.jm-ai-agent-actions { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; }
.jm-ai-agent-actions .ap-btn,
.jm-ai-agent-preview {
    width: auto;
    height: 70px;
    padding: 0 48px 2px;
    border: 0;
    border-radius: 8px;
    font: 300 30px/1 'Myriad', Tahoma, sans-serif;
}
.jm-ai-agent-preview {
    display: inline-flex;
    padding-left: 44px;
    padding-right: 48px;
    align-items: center;
    justify-content: center;
    gap: 13px;
    background: var(--jm-agent-accent);
    color: #fff;
    transition: background-color .5s;
}
.jm-ai-agent-preview:hover { background: var(--jm-agent-accent-hover); }
.jm-ai-agent-preview .jm-agent-star-icon { width: 28px; height: 28px; flex: 0 0 28px; fill: currentColor; }
.jm-agent-ai-token { font-weight: inherit; }

.jm-bottom-agent-link {
    display: flex;
    width: 100%;
    min-height: 100%;
    padding: 30px;
    flex-direction: column;
    align-items: center;
    border: 0;
    border-radius: 8px;
    background: #1b1b1b;
    color: #fff;
    font: inherit;
    text-align: center;
    transition: background-color .5s ease;
}
.jm-bottom-agent-link:hover { background: rgba(255,255,255,.2); }
.jm-bottom-agent-icon-wrap { display: flex; min-height: 70px; margin-bottom: 20px; align-items: center; justify-content: center; }
.jm-bottom-agent-icon { display: inline-flex; width: 70px; height: 70px; align-items: center; justify-content: center; color: #fff; font-size: 90px; line-height: 1; }
.jm-bottom-agent-label { width: 100%; text-align: center; }
.jm-bottom-agent-label,
.ap-big-messes .ap-u { font-size: 32px; line-height: 1.12; font-weight: 300; }

@media (max-width: 1500px) {
    body.home .ap-bottom-fixed-menu.ap-f-df {
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    .ap-bottom-fixed-menu .ap-btn[data-target="#jm-ai-agent"],
    .ap-bottom-fixed-menu .jm-home-fixed-burger { display: none !important; }
    .ap-bottom-fixed-menu .jm-site-agent-launcher { margin-right: 0; }
}

@media (max-width: 1270px) {
    .ap-bottom-fixed-menu .ap-btn[data-target="#jm-services"] { display: none !important; }
}

@media (max-width: 1110px) {
    .ap-bottom-fixed-menu .ap-btn[data-target="#ap-contacts-title"] { display: none !important; }
}

@media (max-width: 1100px) {
    .jm-bottom-agent-link,
    .ap-big-messes a { padding: 24px; }
}

@media (max-width: 960px) {
    .ap-bottom-fixed-menu .ap-btn[data-target="#ap-cases-title"] { display: none !important; }
}

@media (max-width: 800px) {
    .jm-menu-agent-launcher {
        width: 100%;
        align-self: stretch;
    }
}

@media (max-width: 700px) {
    .ap-bottom-fixed-menu.jm-mobile-scroll-hidden {
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
    .ap-bottom-fixed-menu .jm-site-agent-launcher.jm-mobile-scroll-hidden {
        opacity: 0;
        pointer-events: none;
        transform: translateY(12px);
    }
    body.home .ap-bottom-fixed-menu.ap-f-df {
        bottom: 30px;
        left: 12px;
        right: auto;
        width: auto;
        justify-content: flex-start;
    }
    .ap-bottom-fixed-menu .ap-inner { padding: 0; }
    .ap-bottom-fixed-menu .ap-inner::before { display: none !important; content: none !important; }
    .ap-bottom-fixed-menu .jm-site-agent-launcher { margin-right: 0; }
    .ap-bottom-fixed-menu .ap-r-menu-opener[data-target=".ap-call-panel"] { display: none !important; }
    .ap-bottom-fixed-menu .jm-site-agent-launcher {
        height: 62px;
        padding-left: 20px;
        padding-right: 27px;
        gap: 10px;
        font-size: 26px;
        box-shadow: 0 8px 26px rgba(12, 12, 12, .88);
    }
    .ap-bottom-fixed-menu .jm-home-fixed-ai svg {
        width: .82em;
        height: .82em;
    }

    .jm-ai-agent-actions { flex-direction: column; align-items: stretch; }
    .jm-ai-agent-actions .ap-btn,
    .jm-ai-agent-preview { width: 100%; }
}

@media (max-width: 699px) {
    .ap-bottom-fixed-menu .jm-site-agent-launcher .jm-agent-label-wide { display: none; }
    .ap-bottom-fixed-menu .jm-site-agent-launcher .jm-agent-label-short { display: inline; }
}


/* JMAX AGENT POLISH 06 — layout containment, composer and responsive AI actions. */
.jm-agent-subtitle {
    white-space: nowrap;
}



/* One-line user bubble and composer controls share the same 58px visual height. */
.jm-agent-bubble-user .jm-agent-message-text {
    display: flex;
    min-height: 58px;
    align-items: center;
}
.jm-agent-input-wrap {
    min-height: 84px;
    align-items: center;
    padding-top: 12px;
    padding-bottom: 12px;
}
.jm-agent-overlay .jm-agent-message {
    min-height: 58px;
    height: 58px;
    padding-top: 7px;
    padding-bottom: 7px;
}
.jm-agent-overlay .jm-agent-send {
    width: 164px;
    height: 58px;
    padding: 0 20px;
    border-color: #1e88e5;
    border-radius: 18px;
    background: #1e88e5;
    font-size: 18px;
    font-weight: 400;
}
.jm-agent-send:hover:not(:disabled) {
    border-color: #e5493a;
    background: #e5493a;
}
.jm-agent-send-content { gap: 10px; }
.jm-agent-send-icon {
    width: 25px;
    height: 25px;
    flex: 0 0 auto;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.jm-agent-offer-cta {
    border: 1px solid #1e88e5;
    border-radius: 18px;
    background: #1e88e5;
    letter-spacing: .4px;
    line-height: 1.2;
}
.jm-agent-offer-cta:hover {
    border-color: #e5493a;
    background: #e5493a;
}

/* When desktop actions wrap, both become the width of the longer action. */
@media (max-width: 1815px) and (min-width: 1001px) {
    .jm-ai-agent-actions {
        display: grid;
        width: max-content;
        max-width: 100%;
        grid-template-columns: max-content;
        align-items: stretch;
    }
    .jm-ai-agent-actions .ap-btn,
    .jm-ai-agent-preview {
        width: 100%;
    }
}

/* Compact AI section: list first, then two identical text links. */
@media (max-width: 1000px) {
    .jm-ai-agent-actions {
        display: flex;
        width: 100%;
        margin-top: 24px;
        grid-column: 1 / -1;
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    .jm-ai-agent-actions .ap-btn,
    .jm-ai-agent-preview {
        display: inline-flex !important;
        width: auto !important;
        height: auto !important;
        min-height: 0 !important;
        padding: 3px 0 5px !important;
        align-items: center;
        justify-content: flex-start;
        overflow: visible;
        border: 0 !important;
        border-radius: 0 !important;
        background: transparent !important;
        color: #fff !important;
        font: 300 20px/1.2 'Myriad', Tahoma, sans-serif;
        text-align: left;
    }
    .jm-ai-agent-actions .ap-btn:hover,
    .jm-ai-agent-preview:hover {
        background: transparent !important;
        color: var(--jm-agent-accent) !important;
    }
    .jm-ai-agent-preview .jm-agent-star-icon { display: none; }
    .jm-ai-agent-actions .ap-btn::after,
    .jm-ai-agent-preview::after { content: ' →'; white-space: pre; }
}

@media (max-width: 700px) {
    .jm-agent-subtitle { font-size: 15px; }
    .jm-agent-input-wrap {
        min-height: 82px;
        padding: 11px 11px 11px 15px;
    }
    .jm-agent-overlay .jm-agent-message {
        min-height: 58px;
        height: 58px;
    }
    .jm-agent-send-icon { width: 28px; height: 28px; }
}

@media (max-width: 380px) {
    .jm-agent-subtitle { font-size: 14px; }
}

/* JMAX AGENT POLISH 08 — root-cause cleanup for Agent layout and shared site grids. */
/* Feedback is physically inside .jm-agent-chat now; no fake 70/30 feedback grid is needed. */
.jm-agent-feedback {
    display: block;
    width: 100%;
    min-width: 0;
    max-height: 32%;
    padding: 12px 0 0;
    overflow-x: hidden;
    overflow-y: auto;
}
.jm-agent-feedback > * {
    min-width: 0;
    margin-left: 0;
    margin-right: 0;
}
.jm-agent-captcha {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
}
.jm-agent-captcha > div,
.jm-agent-captcha iframe {
    display: block;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

/* The button itself owns line-height; the generic .jm-agent-overlay button rule is more specific than a bare class. */
.jm-agent-overlay .jm-agent-offer-cta {
    line-height: 1.2;
}
.jm-agent-offer-label { display: inline; }
.jm-agent-offer-keep,
.jm-agent-offer-tail { white-space: nowrap; }

/* Label-visible send state: only the left inset is custom. */
.jm-agent-overlay .jm-agent-send {
    padding: 0 20px 0 15px;
    align-self: flex-end;
}

/* Messenger cards use the exact same .ap-c-3 grid as the three form columns above. */
.ap-big-messes {
    align-items: stretch;
}
.ap-big-messes > .jm-agent-big-messenger-item {
    min-width: 0;
}
.ap-big-messes > .jm-agent-big-messenger-item > a,
.ap-big-messes > .jm-agent-big-messenger-item > button {
    width: 100%;
    height: 100%;
}
.jm-bottom-agent-icon {
    display: block;
    color: #fff;
}
.jm-bottom-agent-label,
.ap-big-messes .ap-u {
    font-size: 32px;
    line-height: 1.12;
    font-weight: 300;
    white-space: nowrap;
}

@media (max-width: 2550px) {
    .jm-bottom-agent-label,
    .ap-big-messes .ap-u {
        font-size: clamp(18px, calc(10px + .86vw), 31.9px);
    }
}

/* Compact AI actions are the same two text links, typographically identical. */
@media (max-width: 1000px) {
    .jm-ai-agent-card {
        display: flex;
        flex-direction: column;
        align-items: stretch;
    }
    .jm-ai-agent-copy { display: contents; }
    .jm-ai-agent-copy .jm-section-kicker { order: 1; }
    .jm-ai-agent-copy h2 { order: 2; }
    .jm-ai-agent-copy > p { order: 3; }
    .jm-ai-agent-scenarios { order: 4; }
    .jm-ai-agent-actions {
        order: 5;
        align-self: flex-start;
    }
    .jm-ai-agent-mount { order: 6; }

    .jm-ai-agent-actions .ap-btn,
    .jm-ai-agent-preview {
        font-family: 'Myriad', Tahoma, sans-serif !important;
        font-size: 20px !important;
        font-weight: 300 !important;
        line-height: 1.2 !important;
        color: #fff !important;
    }
    .jm-agent-overlay .jm-agent-send {
        width: auto;
        padding: 0 15px;
    }
    .jm-agent-send-label { display: none; }
}

@media (max-width: 842px) {
    .jm-agent-overlay .jm-agent-offer-cta {
        padding-top: 10px;
        padding-bottom: 10px;
    }
}

@media (max-width: 700px) {
    .jm-agent-feedback {
        padding: 12px 0 0;
    }
    .jm-ai-agent-actions {
        order: 5 !important;
        margin-top: 30px;
        align-self: stretch;
    }
    /* Do not create a second mobile layout for messenger cards; .ap-c-3 follows the form fields. */
    .ap-big-messes > .jm-agent-big-messenger-item {
        min-width: 0;
    }
}


/* JMAX AGENT POLISH 13 — final CTA cascade fixes. */
@media (max-width: 1200px) {
    .ap-big-messes {
        align-items: center;
    }
}

@media (min-width: 701px) and (max-width: 1000px) {
    .jm-ai-agent-actions {
        gap: 24px;
    }
}
