/* Ennui Nation: Help Hub. Reuses the site's collection-page components (screen.css + collection.css);
   this file only adds what is unique to Help Hub: Thistlewood's mark, the access box, the chat window and a few layouts. */
.gx { --en-accent: var(--ghost-accent-color, #F9D432); --gx-line: rgba(255, 255, 255, 0.18); }
.gx [hidden] { display: none !important; }
.gx .gh-inner { max-width: 1040px; }
.gx h2.en-col-label { line-height: 1.4; }
.gx-sec > .cx-lede { margin-bottom: 18px; }
.gx-sec .en-details { margin: 0 0 10px; }
.gx a:not(.en-col-btn):not(.gh-button) { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.gx a:not(.en-col-btn):not(.gh-button):hover { color: var(--en-accent); }
.gx .en-col-btn { font: inherit; font-size: 1.5rem; font-weight: 600; background: transparent; cursor: pointer; transition: border-color .2s ease, filter .2s ease; }
.gx .en-col-btn:hover { border-color: var(--en-accent); }
.gx .en-col-btn.is-primary { background: var(--en-accent); }
.gx .en-col-btn.is-primary:hover { filter: brightness(1.08); }
.gx .en-col-btn[disabled] { opacity: .4; cursor: not-allowed; filter: none; }
.gx .en-col-btn:focus-visible, .gx button:focus-visible, .gx input:focus-visible { outline: 2px solid var(--en-accent); outline-offset: 2px; }
.gx-btns { display: flex; flex-wrap: wrap; gap: 10px; }
.gx-btns-center { justify-content: center; }
.gx-small, .gx-note { margin: 12px 0 0; font-size: 1.4rem; opacity: .75; }

/* Hero: same structure as the collection pages */
.gx .cx-hero-art { color: var(--en-accent); }
.gx-hero-lede { max-width: 640px; margin: 18px auto 24px; font-size: 1.7rem; line-height: 1.55; opacity: .85; }

/* Thistlewood's mark */
.gx-orb { position: relative; flex: none; display: inline-block; width: 48px; height: 48px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff6c4 0%, var(--en-accent) 40%, #a88500 100%); box-shadow: 0 0 28px rgba(249, 212, 50, .3); }
.gx-orb::after { content: ""; position: absolute; inset: -8px; border-radius: 50%; border: 1px solid rgba(249, 212, 50, .4); animation: gx-breathe 4s ease-in-out infinite; }
.gx-orb.is-small { width: 26px; height: 26px; box-shadow: none; }
.gx-orb.is-small::after, .gx-orb.is-tiny::after { display: none; }
.gx-orb.is-tiny { width: 12px; height: 12px; box-shadow: none; }
@keyframes gx-breathe { 0%, 100% { transform: scale(.92); opacity: .2; } 50% { transform: scale(1.08); opacity: .8; } }

/* Guide initials (no emoji) */
.gx-mono { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--en-accent); color: var(--en-accent); font-size: 1.5rem; font-weight: 700; line-height: 1; }
.gx-mono.is-small { width: 26px; height: 26px; font-size: 1.2rem; }
.is-soon .gx-mono { border-color: rgba(255, 255, 255, .35); color: rgba(255, 255, 255, .75); }

/* Access box */
.gx-access { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 16px 22px; align-items: start; padding: clamp(20px, 3vw, 32px); border: 1px solid var(--en-accent); border-radius: 10px; }
.gx-access-title { margin: 0 0 8px; font-size: clamp(2rem, 1vw + 1.6rem, 2.6rem); line-height: 1.25; }
.gx-access p { margin: 0 0 16px; font-size: 1.6rem; line-height: 1.55; opacity: .85; }
.gx-access p.gx-small { margin: 12px 0 0; font-size: 1.4rem; opacity: .75; }
.gx-ack { display: flex; gap: 12px; align-items: flex-start; margin: 0 0 16px; font-size: 1.6rem; line-height: 1.5; cursor: pointer; }
.gx-ack input { flex: none; width: 20px; height: 20px; margin-top: 3px; accent-color: var(--en-accent); cursor: pointer; }
.gx-danger { display: flex; gap: 12px; align-items: flex-start; margin-top: 12px; padding: 14px 18px; border: 1px solid var(--gx-line); border-radius: 8px; font-size: 1.5rem; line-height: 1.5; }
.gx-danger strong { color: var(--en-accent); }
.gx-danger svg { flex: none; width: 22px; height: 22px; margin-top: 1px; color: var(--en-accent); }

/* Problem picker (site filter chips) */
.gx-chips { margin-bottom: 4px; }
.gx-chips .cx-mark-btn { text-align: left; line-height: 1.3; padding-top: 8px; padding-bottom: 8px; }
.gx-answer { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px 16px; align-items: start; }
.gx-answer p { margin: 0; font-size: 1.6rem; line-height: 1.55; }
.gx-answer .gx-answer-who { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; margin-bottom: 6px; font-size: 1.7rem; font-weight: 600; }
.gx-answer .gx-answer-meta { margin-top: 8px; font-size: 1.4rem; opacity: .75; }

/* Status labels */
.gx-badge { display: inline-flex; align-items: center; min-height: 24px; padding: 0 9px; font-size: 1.2rem; font-weight: 600; letter-spacing: .04em; border-radius: 4px; white-space: nowrap; }
.gx-badge.is-live { color: #000; background: var(--en-accent); }
.gx-badge.is-soon { border: 1px solid rgba(255, 255, 255, .35); opacity: .85; }

/* How it works: the site's numbered boxes, three across */
.gx-steps b { font-weight: 600; }
@media (min-width: 900px) { .gx-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* Chat window */
.gx-chat { overflow: hidden; border: 1px solid var(--gx-line); border-radius: 10px; background: #0a0a0a; }
.gx-chat-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--gx-line); }
.gx-chat-who { display: flex; align-items: center; gap: 10px; min-width: 0; font-size: 1.5rem; }
.gx-chat-who b { color: var(--en-accent); }
.gx-chat-who [data-gx-area] { opacity: .75; }
.gx-chat-tag { flex: none; font-size: 1.2rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; opacity: .6; }
.gx-msgs { display: flex; flex-direction: column; gap: 14px; height: 400px; padding: 18px 16px; overflow-y: auto; }
.gx-msg { max-width: 82%; font-size: 1.6rem; line-height: 1.55; }
.gx-msg-name { display: flex; align-items: center; gap: 7px; margin-bottom: 5px; font-size: 1.2rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--en-accent); }
.gx-msg-body { padding: 11px 15px; border: 1px solid var(--gx-line); border-radius: 2px 10px 10px 10px; }
.gx-msg.is-you { align-self: flex-end; }
.gx-msg.is-you .gx-msg-name { justify-content: flex-end; color: inherit; opacity: .7; }
.gx-msg.is-you .gx-msg-body { color: #000; background: var(--en-accent); border-color: var(--en-accent); border-radius: 10px 2px 10px 10px; }
.gx-msg.is-system { align-self: center; max-width: 100%; font-size: 1.3rem; text-align: center; opacity: .65; }
.gx-typing { display: inline-flex; gap: 5px; padding: 13px 15px; border: 1px solid var(--gx-line); border-radius: 2px 10px 10px 10px; }
.gx-typing i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .5; animation: gx-dot 1s infinite ease-in-out; }
.gx-typing i:nth-child(2) { animation-delay: .15s; }
.gx-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes gx-dot { 0%, 80%, 100% { opacity: .25; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
.gx-replies { display: flex; flex-wrap: wrap; gap: 10px; padding: 0 16px 14px; }
.gx-chat-input { display: flex; gap: 10px; padding: 12px 16px; border-top: 1px solid var(--gx-line); }
.gx-chat-input input { flex: 1; min-width: 0; min-height: 44px; padding: 0 14px; font: inherit; font-size: 1.6rem; color: inherit; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .28); border-radius: 6px; }
.gx-chat-input input:disabled { opacity: .6; }
.gx-chat-foot { margin: 0; padding: 0 16px 14px; font-size: 1.3rem; line-height: 1.5; opacity: .7; }
.gx-demo-controls { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; margin-top: 12px; font-size: 1.4rem; }
.gx-demo-controls span { opacity: .7; }

/* Guides: Thistlewood, then the site's open-on-tap boxes */
.gx-lead { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px 20px; align-items: center; margin-bottom: 16px; border-color: var(--en-accent); }
.gx-lead-name { margin: 0 0 4px; font-size: 2rem; font-weight: 700; }
.gx-lead-text { margin: 0; font-size: 1.6rem; line-height: 1.55; opacity: .85; }
.gx-guides { margin-top: 4px; }
.gx-guides li.en-q[hidden] { display: none; }
.gx-guides .en-q-btn { align-items: center; }
.gx .en-q-btn .en-rung-plus { position: static; }
.gx-adv-text { flex: 1; min-width: 0; }
.gx-adv-name { display: block; font-size: 1.6rem; font-weight: 600; }
.gx-adv-area { display: block; font-size: 1.4rem; opacity: .75; }
.gx-guides .en-q-text { padding-left: 62px; }
.gx-guides .en-q-text .gx-badge { margin-top: 10px; }
.gx-guides li.en-q.is-open { border-color: var(--en-accent); }

/* Will / won't */
.gx-two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.gx-list-title { margin: 0 0 12px; font-size: 1.7rem; font-weight: 600; }
.gx-list ul { display: grid; gap: 9px; margin: 0; padding: 0; list-style: none; }
.gx-list li { position: relative; padding-left: 26px; font-size: 1.5rem; line-height: 1.5; }
.gx-list li::before { position: absolute; left: 0; top: 0; font-weight: 700; }
.gx-list.is-will li::before { content: "\2713"; color: var(--en-accent); }
.gx-list.is-wont li::before { content: "\2715"; opacity: .55; }

/* Trust: the site's grade boxes, with icons in place of letters */
.gx-trust .en-grade-letter svg { width: 22px; height: 22px; }
@media (min-width: 760px) { .gx-trust.en-grade-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Privacy */
.gx-privacy { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.gx-privacy li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: start; font-size: 1.6rem; line-height: 1.55; }
.gx-privacy svg { width: 20px; height: 20px; margin-top: 3px; color: var(--en-accent); }


@media (max-width: 699px) {
    .gx-two { grid-template-columns: 1fr; }
    .gx-access, .gx-lead, .gx-answer { grid-template-columns: 1fr; }
    .gx-msg { max-width: 92%; }
    .gx-msgs { height: 360px; padding: 14px 12px; }
    .gx-guides .en-q-text { padding-left: 14px; }
    .gx-chat-tag { display: none; }
    .gx-btns-center .en-col-btn { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) {
    .gx *, .gx *::before, .gx *::after { animation: none !important; transition: none !important; }
}

/* Chat messages: paragraphs, a drafted letter, and reply choices on the reader's side */
.gx-msg-body p { margin: 0 0 .75em; }
.gx-msg-body p:last-child { margin-bottom: 0; }
.gx-msg-name .gx-mono.is-tiny { width: 18px; height: 18px; font-size: 1rem; border-width: 1px; }
.gx-letter { margin: 12px 0 14px; padding: 14px 16px; font-size: 1.5rem; line-height: 1.6; color: #111; background: #f6f3e8; border-left: 3px solid var(--en-accent); border-radius: 4px; }
.gx-letter p { margin: 0 0 .8em; }
.gx-replies { justify-content: flex-end; align-items: center; }
.gx-replies-label { flex: 1 1 100%; margin: 0; font-size: 1.2rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; text-align: right; opacity: .6; }
.gx .gx-reply { text-align: left; line-height: 1.35; white-space: normal; }
@media (min-width: 900px) { .gx-msgs { height: 520px; } .gx-msg { max-width: 74%; } }
@media (max-width: 699px) { .gx .gx-reply { flex: 1 1 100%; justify-content: flex-start; } .gx-replies-label { text-align: left; } }

/* Guide detail (for the guides that are built) */
.gx-adv-more { margin: 0 0 12px; }
.gx-detail { display: grid; gap: 10px; margin: 0 0 12px; }
.gx-detail div { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 4px 16px; }
.gx-detail dt { font-size: 1.3rem; font-weight: 600; letter-spacing: .02em; color: var(--en-accent); }
.gx-detail dd { margin: 0; }
@media (max-width: 699px) { .gx-detail div { grid-template-columns: 1fr; } }

/* Layout pass (phone, tablet, laptop, desktop) */
.gx .cx-lede { max-width: 72ch; text-wrap: pretty; }
.gx-hero-lede { text-wrap: balance; }
.gx .en-questions { align-items: start; }
.gx-steps.en-questions { grid-template-columns: 1fr; }
@media (min-width: 900px) { .gx-steps.en-questions { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.gx-chat-intro { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; height: 100%; padding: 12px; text-align: center; }
.gx-chat-intro p { max-width: 44ch; margin: 0; font-size: 1.6rem; line-height: 1.55; opacity: .85; text-wrap: balance; }
.gx-chat-intro .gx-orb { width: 56px; height: 56px; }
.gx .gx-adv-toggle { display: none; }
@media (max-width: 699px) {
    .gx-access > .gx-orb { display: none; }
    .gx-access .gx-btns .en-col-btn { flex: 1 1 100%; }
    .gx-lead { grid-template-columns: auto minmax(0, 1fr); }
    .gx-lead .gx-orb { width: 36px; height: 36px; }
    .gx-guides:not(.is-all) li.en-q:nth-child(n+7) { display: none; }
    .gx .gx-adv-toggle { display: inline-flex; margin-top: 10px; }
    .gx .gx-guides.is-all + .gx-adv-toggle { display: none; }
}

/* Chip answer action, and visitor-only blocks hidden for supporters */
.gx .gx-answer-go { margin-top: 14px; }
.gx [hidden] { display: none !important; }
@media (max-width: 499px) { .gx-chat-who [data-gx-area] { display: none; } }
/* The guides that are built get a full-width row, so their detail has room */
.gx-guides li.en-q:not(.is-soon) { grid-column: 1 / -1; }
.gx-guides li.en-q:not(.is-soon) .en-q-text { max-width: 820px; }
.gx .gx-steps.en-questions { align-items: stretch; }

/* ===== Alignment system (matches the site) =====
   Centre: hero, section headings and their short intros, short notes, empty states, the closing support box.
   Left: body text, lists, cards, accordions, FAQ answers, anything longer than a couple of lines.
   Right: the reader's own chat messages and reply choices, and open/close (+) icons.
   Width: reading blocks sit in the site's 760px centred column; card grids use the full 1040px column. */
.gx-narrow,
#gx-access > .gx-access, #gx-access > .gx-danger, .gx-lead, #gx-access > [data-gx-view="chat"],
.gx [data-gx-chat="demo"], .gx-answer,
section[aria-labelledby="gx-privacy-h"] > .en-col-extra,
section[aria-labelledby="gx-faq-h"] > .en-details { max-width: 760px; margin-left: auto; margin-right: auto; }
section[aria-labelledby="gx-faq-h"] > .en-details { margin-bottom: 10px; }
.gx .gx-answer { margin-top: 8px; }
@media (min-width: 700px) {
    .gx-sec > .en-col-label { text-align: center; }
    .gx-sec > .cx-lede { max-width: 62ch; margin-left: auto; margin-right: auto; text-align: center; text-wrap: balance; }
    .gx-chips, #gx-guides > .cx-marks { justify-content: center; }
    .gx-sec > .en-rung-show:not(.gx-adv-toggle) { display: flex; margin-left: auto; margin-right: auto; }
    .gx-sec > .gx-note { text-align: center; }
    .gx .gx-adv-toggle { margin-left: auto; margin-right: auto; }
}@media (max-width: 699px) { .gx-lead { align-items: start; } }

/* Short landscape screens (phones on their side): the example chat fits on one screen with its input */
@media (orientation: landscape) and (max-height: 600px) { .gx-msgs { height: calc(100svh - 260px); min-height: 140px; padding-top: 10px; padding-bottom: 10px; } }

/* ===== The real chat (supporters), the preview key box and the closed state ===== */
.gx-key-label { display: block; margin: 0 0 8px; font-size: 1.5rem; font-weight: 600; }
.gx-key-row { display: flex; flex-wrap: wrap; gap: 10px; }
.gx-key-row input { flex: 1 1 240px; min-width: 0; min-height: 46px; padding: 0 14px; font: inherit; font-size: 1.6rem; color: inherit; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .28); border-radius: 6px; }
.gx-chat-input textarea { flex: 1; min-width: 0; min-height: 46px; max-height: 160px; padding: 10px 14px; font: inherit; font-size: 1.6rem; line-height: 1.5; color: inherit; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .28); border-radius: 6px; resize: none; }
.gx-chat-input textarea:disabled { opacity: .6; }
.gx textarea:focus-visible { outline: 2px solid var(--en-accent); outline-offset: 2px; }
.gx-chat-input { align-items: flex-end; }
.gx-msg-body p { white-space: pre-wrap; overflow-wrap: anywhere; }
.gx-msg.is-care .gx-msg-body { border-color: var(--en-accent); border-left-width: 4px; }
.gx-msg.is-system.is-error { opacity: 1; padding: 8px 12px; font-weight: 500; color: #000; background: var(--en-accent); border-radius: 8px; }
.gx-linkbtn { padding: 0; font: inherit; color: var(--en-accent); background: none; border: 0; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.gx-preview-forget { max-width: 760px; margin-left: auto; margin-right: auto; text-align: center; }
#gx-access > [data-gx-view] { max-width: 760px; margin-left: auto; margin-right: auto; }
@media (max-width: 699px) {
    .gx-chat-input { flex-direction: column; align-items: stretch; }
    .gx-key-row .en-col-btn { flex: 1 1 100%; }
}
/* ===== Examples: grouped list beside the chat (laptop and desktop); one button that opens the same list (tablet and phone).
   Nothing scrolls sideways at any width. ===== */
.gx-demo { display: grid; gap: 12px; max-width: 760px; margin: 0 auto; }
.gx .gx-demo [data-gx-chat="demo"] { max-width: none; margin: 0; }
.gx-ex-bar { display: grid; grid-template-columns: 46px minmax(0, 1fr) 46px; gap: 8px; }
.gx-ex-step, .gx-ex-toggle { min-height: 46px; font: inherit; color: inherit; background: transparent; border: 1px solid rgba(255, 255, 255, .28); border-radius: 8px; cursor: pointer; transition: border-color .2s ease; }
.gx-ex-step { display: inline-flex; align-items: center; justify-content: center; padding: 0; }
.gx-ex-step svg { width: 20px; height: 20px; }
.gx-ex-toggle { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-width: 0; padding: 8px 14px; font-size: 1.5rem; font-weight: 600; line-height: 1.3; text-align: left; border-color: var(--en-accent); }
.gx-ex-toggle span { min-width: 0; overflow-wrap: anywhere; }
.gx-ex-toggle svg { flex: none; width: 20px; height: 20px; color: var(--en-accent); transition: transform .2s ease; }
.gx-ex-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.gx-ex-step:hover, .gx-ex-toggle:hover { border-color: var(--en-accent); }
.gx-ex-step:focus-visible, .gx-ex-toggle:focus-visible { outline: 2px solid var(--en-accent); outline-offset: 2px; }
.gx-ex-menu { display: none; gap: 16px; padding: 16px 12px; border: 1px solid var(--gx-line); border-radius: 10px; background: #0a0a0a; }
.gx-ex-menu.is-open { display: grid; }
.gx-ex-group { display: grid; gap: 2px; }
.gx-ex-title { margin: 0 0 4px; padding-left: 10px; font-size: 1.2rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--en-accent); }
.gx-ex-btn { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 8px 10px; font: inherit; font-size: 1.5rem; font-weight: 500; line-height: 1.3; text-align: left; color: inherit; background: transparent; border: 1px solid transparent; border-radius: 8px; cursor: pointer; transition: border-color .2s ease, background-color .2s ease; }
.gx-ex-btn:hover { border-color: rgba(255, 255, 255, .28); background: rgba(255, 255, 255, .04); }
.gx-ex-btn[aria-pressed="true"], .gx-ex-btn[aria-pressed="true"]:hover { color: #000; background: var(--en-accent); border-color: var(--en-accent); }
.gx-ex-btn[aria-pressed="true"] .gx-mono { color: #000; border-color: #000; }
.gx-ex-btn[aria-pressed="true"] .gx-orb { background: #000; }
.gx-ex-btn .gx-mono.is-tiny { flex: none; width: 22px; height: 22px; font-size: 1.1rem; }
.gx-ex-btn .gx-orb.is-tiny { flex: none; width: 14px; height: 14px; margin: 0 4px; }
.gx-ex-btn:focus-visible { outline: 2px solid var(--en-accent); outline-offset: 2px; }
@media (min-width: 560px) and (max-width: 999px) { .gx-ex-menu.is-open { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 20px; } }
@media (min-width: 1000px) {
    .gx-demo { grid-template-columns: 290px minmax(0, 1fr); gap: 24px; max-width: none; align-items: start; }
    .gx-ex-bar { display: none; }
    .gx-ex-menu, .gx-ex-menu.is-open { display: grid; grid-template-columns: none; gap: 18px; padding: 0; border: 0; background: none; position: sticky; top: 24px; }
    .gx-ex-btn { font-size: 1.4rem; min-height: 40px; }
}
/* Example chat: no typing box, the reply choices sit where you would type */
.gx-replies.is-demo { min-height: 64px; margin: 0; padding: 14px 16px; border-top: 1px solid var(--gx-line); }
.gx-replies.is-demo:empty { padding: 0; min-height: 0; border-top: 0; }
.gx-replies-label { margin-bottom: 2px; }
.gx-chat-foot { padding-top: 12px; border-top: 1px solid var(--gx-line); }
.gx-chat-tag { white-space: nowrap; }
@media (min-width: 1000px) { .gx-demo .gx-msgs { height: 560px; } }

/* Real chat: End chat in the header, the message box and Send side by side on every screen */
.gx-chat-tools { display: flex; align-items: center; gap: 12px; flex: none; }
.gx-end { min-height: 34px; padding: 0 12px; font: inherit; font-size: 1.3rem; font-weight: 600; color: inherit; background: transparent; border: 1px solid rgba(255, 255, 255, .35); border-radius: 6px; cursor: pointer; }
.gx-end:hover { border-color: var(--en-accent); }
.gx-end:disabled { opacity: .5; cursor: wait; }
.gx-end:focus-visible { outline: 2px solid var(--en-accent); outline-offset: 2px; }
.gx [data-gx-chat="live"] .gx-chat-input { flex-direction: row; align-items: flex-end; }
.gx [data-gx-chat="live"] .gx-chat-input .en-col-btn { flex: none; min-height: 46px; }
.gx-input-hint { margin: -4px 0 0; padding: 0 16px 10px; font-size: 1.25rem; opacity: .6; }
@media (hover: none) { .gx-input-hint { display: none; } }
@media (max-width: 699px) {
    .gx [data-gx-chat="live"] .gx-chat-tag { display: none; }
    .gx [data-gx-chat="live"] .gx-msgs { height: calc(100svh - 250px); min-height: 300px; max-height: 560px; }
    .gx-demo .gx-msgs { height: calc(100svh - 300px); min-height: 300px; max-height: 520px; }
    .gx-chat-top { padding: 10px 12px; }
    .gx-chat-input, .gx-replies.is-demo { padding-left: 12px; padding-right: 12px; }
    .gx-chat-foot { padding-left: 12px; padding-right: 12px; font-size: 1.25rem; }
    .gx-demo .gx-chat-tag { display: inline; font-size: 1.1rem; }
}
@media (max-width: 499px) {
    .gx-chat-who .gx-speaking, .gx-count-word { display: none; }
    .gx-chat-who { font-size: 1.6rem; }
}@media (max-width: 999px) { .gx-demo [data-gx-count] { display: none; } }

/* ===== The real chat as its own screen (27 Oct 2026) =====
   It fills the screen and stays put; only the conversation scrolls. Reading column of about 720px, calm type, gold scrollbars. */
html.gx-locked, html.gx-locked body { overflow: hidden; }
.gx-stage { position: fixed; inset: 0; z-index: 9999; display: flex; color: #fff; background: #000; color-scheme: dark; }
.gx-stage .gx-col, .gx-stage .gx-chat-top { animation: gx-stage-in .25s ease-out; }
@keyframes gx-stage-in { from { transform: translateY(10px); } to { transform: none; } }
.gx-stage [data-gx-chat="live"] { display: flex; flex-direction: column; flex: 1; min-width: 0; height: 100%; height: 100dvh; max-width: none; margin: 0; border: 0; border-radius: 0; background: #000; }
.gx-stage .gx-chat-top { flex: none; padding: 10px max(16px, calc((100% - 960px) / 2)); background: #000; }
.gx-stage .gx-chat-tools { gap: 8px; }
.gx-tool { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 36px; padding: 0 12px; font: inherit; font-size: 1.3rem; font-weight: 600; color: inherit; background: transparent; border: 1px solid rgba(255, 255, 255, .35); border-radius: 6px; cursor: pointer; }
.gx-tool:hover, .gx-tool[aria-expanded="true"] { border-color: var(--en-accent); color: var(--en-accent); }
.gx-tool.gx-hide { width: 36px; padding: 0; }
.gx-tool svg { width: 18px; height: 18px; }
.gx-stage .gx-end { min-height: 36px; }
.gx-help-panel { flex: none; max-height: 45vh; overflow-y: auto; padding: 14px max(16px, calc((100% - 720px) / 2)); border-bottom: 1px solid var(--gx-line); background: #0b0b0b; font-size: 1.45rem; line-height: 1.5; }
.gx-help-panel > svg { display: none; }
.gx-help-panel strong { color: var(--en-accent); }
.gx-stage [data-gx-chat="live"] .gx-msgs { flex: 1; height: auto; min-height: 0; max-height: none; padding: 24px 16px 12px; overscroll-behavior: contain; scroll-behavior: smooth; }
.gx-col { width: 100%; max-width: 720px; margin: 0 auto; display: flex; flex-direction: column; gap: 22px; }
.gx-stage .gx-msg { max-width: 100%; font-size: 1.55rem; line-height: 1.65; }
/* Guides write on the page, not in a box; the reader's own words sit in a gold bubble on the right */
.gx-stage .gx-msg:not(.is-you):not(.is-system) .gx-msg-body { padding: 0; border: 0; border-radius: 0; }
.gx-stage .gx-msg.is-you { max-width: 85%; }
.gx-stage .gx-msg.is-you .gx-msg-body { padding: 10px 14px; border-radius: 14px 4px 14px 14px; }
.gx-stage .gx-msg.is-care .gx-msg-body { padding: 12px 16px; border: 1px solid var(--en-accent); border-left-width: 4px; border-radius: 4px 10px 10px 4px; }
.gx-stage .gx-msg-body p { white-space: normal; margin: 0 0 .8em; }
.gx-stage .gx-msg.is-you .gx-msg-body p { white-space: pre-wrap; }
.gx-msg-body > :last-child { margin-bottom: 0; }
.gx-msg-body strong { font-weight: 700; color: #fff; }
.gx-msg-body em { font-style: italic; }
.gx-msg-body code { padding: 1px 5px; font-size: .92em; background: rgba(255, 255, 255, .08); border-radius: 4px; }
.gx-msg-body .gx-h { margin: 1em 0 .4em; font-weight: 700; color: var(--en-accent); }
.gx-msg-body ul, .gx-msg-body ol { margin: 0 0 .8em; padding-left: 1.3em; }
.gx-msg-body li { margin: 0 0 .35em; padding-left: .2em; }
.gx-msg-body ul li::marker { color: var(--en-accent); }
.gx-msg-body ol li::marker { color: var(--en-accent); font-weight: 700; }
.gx-msg-body blockquote { margin: 0 0 .8em; padding: 2px 0 2px 14px; border-left: 3px solid var(--en-accent); opacity: .9; }
.gx-msg-body a { overflow-wrap: anywhere; }
.gx-msg-body .gx-tel { font-weight: 700; color: var(--en-accent); white-space: nowrap; }
.gx-msg.is-you .gx-msg-body strong, .gx-msg.is-you .gx-msg-body .gx-tel { color: #000; }
.gx-pending { opacity: 0; }
.gx-msg-body p, .gx-msg-body li, .gx-msg-body blockquote, .gx-letter, .gx-chart { transition: opacity .25s ease; }
.gx-msg-body[aria-busy="true"] { cursor: pointer; }
.gx-stage .gx-msg.is-system { font-size: 1.25rem; letter-spacing: .02em; }

/* Status while a reply is on its way */
.gx-stage .gx-typing { align-items: center; gap: 10px; padding: 0; border: 0; font-size: 1.4rem; }
.gx-dots { display: inline-flex; gap: 5px; }
.gx-dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--en-accent); opacity: .5; animation: gx-dot 1s infinite ease-in-out; }
.gx-dots i:nth-child(2) { animation-delay: .15s; }
.gx-dots i:nth-child(3) { animation-delay: .3s; }
.gx-status { opacity: .75; }
.gx-status:not(:empty) { animation: gx-fade .3s ease; }
@keyframes gx-fade { from { opacity: 0; } to { opacity: .75; } }

/* A letter to adapt, and simple charts */
.gx-letter { margin: 4px 0 .9em; padding: 0 18px 14px; color: #111; background: #fbfaf5; border-radius: 8px; border-top: 4px solid var(--en-accent); font-size: 1.45rem; line-height: 1.6; }
.gx-letter-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 -18px 12px; padding: 8px 12px 8px 18px; font-size: 1.15rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #6b5800; background: #f3eed8; }
.gx-letter p { margin: 0 0 .8em; overflow-wrap: anywhere; }
.gx-letter .gx-ph { padding: 0 3px; font-weight: 600; background: rgba(249, 212, 50, .45); border-radius: 3px; }
.gx-copy { min-height: 30px; padding: 0 12px; font: inherit; font-size: 1.2rem; font-weight: 700; letter-spacing: .04em; text-transform: none; color: #000; background: var(--en-accent); border: 0; border-radius: 5px; cursor: pointer; }
.gx-copy:focus-visible { outline: 2px solid #000; outline-offset: 2px; }
.gx-chart { margin: 4px 0 .9em; padding: 14px 16px; border: 1px solid var(--gx-line); border-radius: 8px; }
.gx-chart figcaption { margin: 0 0 10px; font-size: 1.3rem; font-weight: 700; color: var(--en-accent); }
.gx-chart-rows { display: grid; gap: 8px; }
.gx-chart-row { display: grid; grid-template-columns: minmax(0, 9em) minmax(0, 1fr) auto; align-items: center; gap: 10px; font-size: 1.3rem; }
.gx-chart-label { overflow-wrap: anywhere; opacity: .85; }
.gx-chart-track { height: 10px; background: rgba(255, 255, 255, .08); border-radius: 5px; overflow: hidden; }
.gx-chart-bar { display: block; height: 100%; width: var(--w); background: linear-gradient(90deg, #a88500, var(--en-accent)); border-radius: 5px; animation: gx-grow .8s ease-out both; }
@keyframes gx-grow { from { width: 0; } }
.gx-chart-value { font-weight: 600; white-space: nowrap; }

/* The writing box, docked at the bottom */
.gx-dock { flex: none; padding: 10px 16px max(12px, env(safe-area-inset-bottom)); border-top: 1px solid var(--gx-line); background: #000; }
.gx-dock .gx-col { gap: 6px; }
.gx-stage .gx-chat-input { flex-direction: row; align-items: flex-end; gap: 8px; padding: 0; border: 0; }
.gx-stage .gx-chat-input textarea { min-height: 48px; padding: 12px 16px; font-size: 1.55rem; border-radius: 24px; background: #111; border-color: rgba(255, 255, 255, .22); }
.gx-stage .gx-chat-input textarea:focus { border-color: var(--en-accent); outline: none; }
.gx-send { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; padding: 0; color: #000; background: var(--en-accent); border: 0; border-radius: 50%; cursor: pointer; transition: transform .15s ease, opacity .2s ease; }
.gx-send svg { width: 22px; height: 22px; }
.gx-send:hover:not(:disabled) { transform: scale(1.06); }
.gx-mic { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; padding: 0; color: var(--en-accent); background: transparent; border: 1.5px solid var(--en-accent); border-radius: 50%; cursor: pointer; transition: background .15s ease, color .15s ease; }
.gx-mic svg { width: 22px; height: 22px; }
.gx-mic:hover, .gx-mic.is-on { color: #000; background: var(--en-accent); }
.gx-mic.is-on { animation: gx-mic-pulse 1.4s ease-in-out infinite; }
.gx-mic:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
@keyframes gx-mic-pulse { 50% { box-shadow: 0 0 0 6px rgba(249, 212, 50, .28); } }
@media (prefers-reduced-motion: reduce) { .gx-mic.is-on { animation: none; } }
.gx-letter-tools { display: inline-flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.gx-chart-tools { display: flex; justify-content: flex-end; margin-top: 8px; }
.gx-send:disabled { opacity: .35; cursor: default; }
.gx-send:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.gx-stage .gx-input-hint { margin: 0; padding: 0 4px; }
.gx-stage .gx-chat-foot { margin: 0; padding: 0 4px; border: 0; font-size: 1.2rem; }

/* Gold, slim scrollbars on dark (never a white bar) */
.gx-stage, .gx-stage * { scrollbar-width: thin; scrollbar-color: rgba(249, 212, 50, .55) transparent; }
.gx-stage ::-webkit-scrollbar { width: 8px; height: 8px; }
.gx-stage ::-webkit-scrollbar-track { background: transparent; }
.gx-stage ::-webkit-scrollbar-thumb { background: rgba(249, 212, 50, .45); border-radius: 8px; }
.gx-stage ::-webkit-scrollbar-thumb:hover { background: var(--en-accent); }
.gx .gx-msgs { scrollbar-width: thin; scrollbar-color: rgba(249, 212, 50, .55) transparent; }

/* The welcome inside an empty chat */
.gx-stage .gx-chat-intro { min-height: 50vh; }
.gx-intro-title { font-size: 2.2rem !important; font-weight: 700; opacity: 1 !important; }
.gx-stage .gx-chat-intro .gx-orb { width: 88px; height: 88px; }

/* Back to a hidden chat */
.gx-back { position: fixed; right: 16px; bottom: max(16px, env(safe-area-inset-bottom)); z-index: 9998; display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 18px 0 10px; font: inherit; font-size: 1.45rem; font-weight: 700; color: #000; background: var(--en-accent, #F9D432); border: 0; border-radius: 26px; box-shadow: 0 6px 24px rgba(0, 0, 0, .5); cursor: pointer; }
.gx-back[hidden] { display: none; }
.gx-back .gx-orb { background: #000; box-shadow: none; }
.gx-back:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }

/* The danger box: 999 first, then people to talk to */
.gx-danger-body { min-width: 0; }
.gx-danger-body p { margin: 0 0 8px; }
.gx-danger-list { margin: 0; padding-left: 1.2em; font-size: 1.4rem; }
.gx-danger-list li { margin: 0 0 4px; overflow-wrap: anywhere; }
.gx-danger-list li::marker { color: var(--en-accent); }

/* Available now / Coming soon */
.gx-badge.is-live i, .gx-dot.is-live { display: inline-block; width: 8px; height: 8px; margin-right: 7px; border-radius: 50%; background: #1f9d55; box-shadow: 0 0 0 3px rgba(31, 157, 85, .25); }
.gx-badge.is-live i { background: #000; box-shadow: none; animation: gx-pulse 2s ease-in-out infinite; }
.gx-dot { display: inline-block; width: 8px; height: 8px; margin-right: 7px; border-radius: 50%; vertical-align: middle; }
.gx-dot.is-live { background: var(--en-accent); box-shadow: 0 0 0 3px rgba(249, 212, 50, .25); }
.gx-dot.is-soon { background: transparent; border: 1px solid rgba(255, 255, 255, .55); }
@keyframes gx-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }

/* Thistlewood, alive: a swirling gold current with small sparks */
.gx-orb.is-alive { background: none; box-shadow: none; overflow: visible; }
.gx-orb.is-alive::after { display: none; }
.gx-alive { position: absolute; inset: -18%; width: 136%; height: 136%; overflow: visible; }
.gx-alive-swirl { transform-origin: 50px 50px; animation: gx-spin 9s linear infinite; }
.gx-alive-swirl.is-back { animation-duration: 14s; animation-direction: reverse; }
.gx-alive-core { transform-origin: 50px 50px; animation: gx-core 3.6s ease-in-out infinite; }
.gx-alive-glow { transform-origin: 50px 50px; animation: gx-glow 3.6s ease-in-out infinite; }
.gx-alive-sparks path { opacity: 0; animation: gx-spark 4.2s ease-in-out infinite; }
.gx-alive-sparks .s2 { animation-delay: 1.4s; }
.gx-alive-sparks .s3 { animation-delay: 2.8s; }
@keyframes gx-spin { to { transform: rotate(360deg); } }
@keyframes gx-core { 0%, 100% { transform: scale(.94); } 50% { transform: scale(1.04); } }
@keyframes gx-glow { 0%, 100% { opacity: .55; transform: scale(.95); } 50% { opacity: 1; transform: scale(1.05); } }
@keyframes gx-spark { 0%, 70%, 100% { opacity: 0; } 74% { opacity: 1; } 78% { opacity: .2; } 82% { opacity: .9; } 88% { opacity: 0; } }
.gx-orb.is-small:not(.is-alive), .gx-orb.is-tiny { background: conic-gradient(from 0deg, #a88500, #F9D432, #fff6c4, #F9D432, #a88500); animation: gx-spin 6s linear infinite; }

@media (max-width: 699px) {
    .gx-stage .gx-chat-top { padding: 8px 10px; }
    .gx-stage .gx-chat-tools { gap: 6px; }
    .gx-stage .gx-tool[data-gx-help] { padding: 0 8px; font-size: 1.2rem; }
    .gx-stage .gx-msgs { padding: 18px 14px 10px; }
    .gx-stage .gx-msg { font-size: 1.5rem; }
    .gx-dock { padding-left: 10px; padding-right: 10px; }
    .gx-chart-row { grid-template-columns: minmax(0, 1fr) auto; }
    .gx-chart-track { grid-column: 1 / -1; grid-row: 2; }
}
@media (max-width: 420px) { .gx-stage .gx-chat-who [data-gx-area], .gx-stage .gx-chat-who .gx-speaking { display: none; } }
@media (prefers-reduced-motion: reduce) {
    .gx-stage .gx-col, .gx-stage .gx-chat-top, .gx-chart-bar, .gx-status:not(:empty) { animation: none; }
    .gx-alive-swirl, .gx-alive-core, .gx-alive-glow, .gx-alive-sparks path, .gx-orb.is-small, .gx-orb.is-tiny, .gx-dots i, .gx-badge.is-live i { animation: none; }
    .gx-alive-sparks path { opacity: .6; }
    .gx-stage .gx-msgs { scroll-behavior: auto; }
}
.gx-stage .gx-chat-who { flex: 1 1 auto; min-width: 0; }
.gx-stage .gx-chat-who > span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gx-short { display: none; }
@media (max-width: 480px) { .gx-long { display: none; } .gx-short { display: inline; } .gx-stage .gx-end { padding: 0 9px; } }
.gx-stage[hidden] { display: none !important; }
