/* ==========================================================
   GotMama UI

   Everything is namespaced .gm- and every property the theme
   might set is reset explicitly. WordPress themes style h1-h6,
   button and a globally, and without this the headings arrive
   at 48px and the buttons arrive in uppercase.

   Colour: the interface is black and white. Orange appears
   only where something is active or being hovered, so the
   eye is drawn to the one thing that matters.
   ========================================================== */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@600;700&family=Plus+Jakarta+Sans:wght@400;500;600;700&display=swap');

.gm-app {
  --gm-navy:    #15232B;
  --gm-orange:  #E8542B;
  --gm-rust:    #C4502B;
  --gm-tint:    #FDEFE9;

  --gm-legal:   #3E7D99;
  --gm-fin:     #C98424;
  --gm-well:    #4E8A62;

  --gm-page:    #FFFFFF;
  --gm-surface: #FFFFFF;
  --gm-raise:   #F5F4F2;
  --gm-ink:     #15181A;
  --gm-ink-2:   #4A5257;
  --gm-muted:   #8C9398;
  --gm-line:    #E8E6E2;
  --gm-line-2:  #F2F0ED;

  --gm-ui:    "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --gm-serif: "Playfair Display", Georgia, serif;

  --gm-height: 78vh;
  --gm-scale: 1;

  display: grid;
  grid-template-columns: 268px minmax(0, 1fr);
  height: var(--gm-height);
  min-height: 480px;
  border: 1px solid var(--gm-line);
  border-radius: 16px;
  overflow: hidden;
  background: var(--gm-surface);
  font-family: var(--gm-ui);
  font-size: calc(15px * var(--gm-scale));
  line-height: 1.6;
  color: var(--gm-ink);
  letter-spacing: normal;
  text-align: left;
  -webkit-font-smoothing: antialiased;
  box-sizing: border-box;
}

.gm-app.gm-full {
  position: fixed;
  inset: 0;
  z-index: 99990;
  height: 100%;
  border: 0;
  border-radius: 0;
  padding-top: env(safe-area-inset-top, 0px);
}

/* --- defend against the theme ---
   :where() carries no specificity of its own, so these rules sit at
   exactly .gm-app (0,1,0). That is enough to beat a theme's element
   selectors, and low enough that every component rule below can still
   set its own padding. Writing them as .gm-app button would score
   (0,1,1) and silently override the components — which is what went
   wrong the first time. */

.gm-app, .gm-app *, .gm-app *::before, .gm-app *::after { box-sizing: border-box; }

.gm-app :where(h1, h2, h3, h4, h5, h6,
               p, ul, ol, li, dl, dd,
               button, input, textarea, select, label, fieldset) {
  margin: 0;
  padding: 0;
  font-family: var(--gm-ui);
  font-size: inherit;
  letter-spacing: normal;
  text-transform: none;
  line-height: 1.6;
  color: inherit;
}

.gm-app :where(button) {
  background: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  width: auto;
  min-width: 0;
  min-height: 0;
  text-align: left;
  -webkit-appearance: none;
  appearance: none;
}

/* Themes almost always style button:hover (0,1,1). This guard scores
   (0,2,0) so it wins, and every component hover below scores (0,3,0)
   so it still wins over the guard. Without this, hovering a row in
   the settings panel paints it in the theme's button colour. */
.gm-app :where(button):hover,
.gm-app :where(button):focus,
.gm-app :where(button):active {
  background: none;
  color: inherit;
  box-shadow: none;
  transform: none;
}

.gm-app :where(a) { box-shadow: none; text-decoration: none; }
.gm-app :where(svg) { display: block; flex: none; }
.gm-app :where(ul, ol) { list-style: none; }
.gm-app :where(input, textarea) { background: none; }

.gm-app :focus-visible { outline: 2px solid var(--gm-orange); outline-offset: 2px; border-radius: 8px; }

.gm-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ===================== sidebar ===================== */

.gm-app .gm-side {
  background: var(--gm-page);
  border-right: 1px solid var(--gm-line);
  display: flex; flex-direction: column;
  min-height: 0; padding-top: 18px;
}

.gm-app .gm-brand { display: flex; align-items: center; gap: 11px; padding: 0 18px 20px; }

.gm-app .gm-badge {
  width: 42px; height: 31px; flex: none;
  display: grid; place-items: center;
  line-height: 1;
}

/* The mark is drawn, not set in type, so it needs no background
   plate behind it and no colour of its own from the interface. */
.gm-app .gm-mark { display: block; width: 100%; height: 100%; overflow: visible; }

.gm-app .gm-badge .gm-mark { width: 42px; height: 31px; }

.gm-app .gm-wordmark {
  display: block;
  font-family: var(--gm-serif); font-size: 18px; font-weight: 700;
  color: var(--gm-ink); line-height: 1.15;
}
.gm-app .gm-wordmark em { font-style: normal; color: var(--gm-orange); }
.gm-app .gm-tagline { display: block; font-size: 10px; color: var(--gm-muted); font-weight: 500; line-height: 1.4; }

/* outlined, not filled — orange only on hover */
.gm-app .gm-new {
  margin: 0 14px 18px;
  padding: 10px 14px;
  border: 1px solid var(--gm-line) !important;
  border-radius: 11px;
  background: var(--gm-surface);
  color: var(--gm-ink);
  font-size: 13.5px; font-weight: 600;
  display: flex; align-items: center; gap: 9px;
  transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.gm-app .gm-new:hover { border-color: var(--gm-orange) !important; color: var(--gm-orange); background: var(--gm-tint); }

.gm-app .gm-threads { flex: 1; min-height: 0; overflow-y: auto; padding: 0 10px; }

.gm-app .gm-threads-h {
  font-size: 10px; letter-spacing: .1em; text-transform: uppercase !important;
  color: var(--gm-muted); font-weight: 700; padding: 6px 10px 8px;
}

.gm-app .gm-threads-empty { font-size: 13px; color: var(--gm-muted); padding: 4px 10px; font-weight: 500; }

.gm-app .gm-thread-row {
  position: relative;
  display: flex;
  align-items: center;
  gap: 2px;
  border-radius: 9px;
}

.gm-app .gm-thread-row:hover { background: var(--gm-raise); }

.gm-app .gm-thread {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 9px 4px 9px 11px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--gm-ink-2);
  font-family: var(--gm-ui);
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.35;
  text-align: left;
  text-transform: none;
  letter-spacing: normal;
  cursor: pointer;
}

.gm-app .gm-thread:hover { color: var(--gm-ink); background: transparent; }

.gm-app .gm-thread[aria-current="true"] {
  color: var(--gm-ink);
  font-weight: 600;
  box-shadow: inset 2px 0 0 var(--gm-orange);
}

.gm-app .gm-thread span.gm-t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.gm-app .gm-thread-x {
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  margin-right: 5px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--gm-muted);
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.14s ease, color 0.14s ease;
}

.gm-app .gm-thread-row:hover .gm-thread-x,
.gm-app .gm-thread-x:focus-visible { opacity: 1; }

.gm-app .gm-thread-x:hover { color: var(--gm-orange); background: var(--gm-line-2); }

/* A touch screen has no hover, so a control that only appears on
   hover does not exist there at all. On those devices it is
   always visible. */
@media (hover: none) {
  .gm-app .gm-thread-x { opacity: 0.55; }
}

/* ---------- confirming a delete ---------- */

.gm-app .gm-thread-row.gm-thread-ask {
  gap: 6px;
  padding: 7px 8px 7px 11px;
  background: var(--gm-tint);
}

.gm-app .gm-ask-t {
  flex: 1;
  min-width: 0;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--gm-ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.gm-app button.gm-ask-no,
.gm-app button.gm-ask-yes {
  flex: 0 0 auto;
  font-family: var(--gm-ui);
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  text-transform: none;
  letter-spacing: normal;
  padding: 7px 11px;
  border-radius: 7px;
  cursor: pointer;
}

.gm-app button.gm-ask-no {
  border: 1px solid var(--gm-line);
  background: var(--gm-surface);
  color: var(--gm-ink-2);
}

.gm-app button.gm-ask-no:hover { border-color: var(--gm-ink); color: var(--gm-ink); background: var(--gm-surface); }

.gm-app button.gm-ask-yes {
  border: 1px solid var(--gm-rust);
  background: var(--gm-rust);
  color: #fff;
}

.gm-app button.gm-ask-yes:hover { background: #A8401F; border-color: #A8401F; }

/* ---------- clearing everything ---------- */

.gm-app .gm-danger { border-top: 1px solid var(--gm-line); padding-top: 18px; margin-top: 4px; }

.gm-app button.gm-wipe {
  width: 100%;
  margin-top: 10px;
  font-family: var(--gm-ui);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  text-transform: none;
  letter-spacing: normal;
  padding: 11px 14px;
  border: 1px solid var(--gm-line);
  border-radius: 10px;
  background: var(--gm-surface);
  color: var(--gm-ink-2);
  cursor: pointer;
  transition: border-color 0.14s ease, color 0.14s ease, background 0.14s ease;
}

.gm-app button.gm-wipe:hover {
  border-color: var(--gm-rust);
  color: var(--gm-rust);
  background: var(--gm-surface);
}

.gm-app button.gm-wipe.gm-wipe-armed,
.gm-app button.gm-wipe.gm-wipe-armed:hover {
  background: var(--gm-rust);
  border-color: var(--gm-rust);
  color: #fff;
}

.gm-app .gm-side-foot { border-top: 1px solid var(--gm-line); padding: 11px 18px; }

.gm-app .gm-sidelink {
  display: flex; align-items: center; gap: 9px;
  width: 100%; padding: 7px 0;
  font-size: 13px; font-weight: 500; color: var(--gm-ink-2);
  transition: color .13s ease;
}
.gm-app .gm-sidelink:hover { color: var(--gm-orange); }
.gm-app .gm-sidelink svg { color: var(--gm-muted); }
.gm-app .gm-sidelink:hover svg { color: var(--gm-orange); }

.gm-app .gm-side-note { font-size: 11px; color: var(--gm-muted); line-height: 1.5; font-weight: 500; padding-top: 8px; }

/* ===================== main ===================== */

.gm-app .gm-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--gm-surface); }

.gm-app .gm-top {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 22px;
  border-bottom: 1px solid var(--gm-line-2);
  min-height: 60px;
}

.gm-app .gm-ghost {
  display: none;
  border: 1px solid var(--gm-line) !important;
  border-radius: 9px; padding: 7px 9px; color: var(--gm-ink);
  transition: border-color .15s ease, color .15s ease;
}
.gm-app .gm-ghost:hover { border-color: var(--gm-orange) !important; color: var(--gm-orange); background: none; }

.gm-app .gm-title {
  font-size: 15px !important;
  font-weight: 600 !important;
  font-family: var(--gm-ui) !important;
  margin: 0 !important;
  flex: 1; min-width: 0;
  color: var(--gm-ink);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  line-height: 1.4 !important;
  text-transform: none !important;
  letter-spacing: normal !important;
}

.gm-app .gm-tbtn {
  border: 1px solid var(--gm-line) !important;
  border-radius: 10px; padding: 7px 11px;
  font-size: 12.5px; font-weight: 600; color: var(--gm-ink-2);
  display: inline-flex; align-items: center; gap: 7px;
  white-space: nowrap;
  transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.gm-app .gm-tbtn:hover { border-color: var(--gm-orange) !important; color: var(--gm-orange); background: var(--gm-tint); }
.gm-app .gm-tbtn[aria-pressed="true"] {
  border-color: var(--gm-orange) !important;
  color: var(--gm-orange);
  background: var(--gm-tint);
}
.gm-app .gm-tbtn svg { color: currentColor; }

.gm-app .gm-soon {
  font-size: 9px; font-weight: 700; letter-spacing: .07em;
  text-transform: uppercase !important;
  background: var(--gm-raise); color: var(--gm-muted);
  border-radius: 5px; padding: 2px 5px; line-height: 1.3;
}

/* ===================== stream ===================== */

.gm-app .gm-stream { flex: 1; overflow-y: auto; min-height: 0; padding: 28px 22px 8px; scroll-behavior: smooth; }
.gm-app .gm-inner { max-width: 700px; margin: 0 auto; }

.gm-app .gm-row { display: flex; gap: 13px; align-items: flex-start; margin-bottom: 26px; }
.gm-row.gm-me { justify-content: flex-end; }

.gm-app .gm-av {
  width: 37px; height: 27px; flex: none; margin-top: 4px;
  display: grid; place-items: center;
  font-family: var(--gm-serif); font-size: 15px; font-weight: 700; color: #fff;
  line-height: 1;
}

.gm-app .gm-av .gm-mark { width: 37px; height: 27px; }

/* In high contrast the two halves would read as one block, so the
   mark is outlined instead of relying on the colour difference. */
.gm-app[data-gm-vision="contrast"] .gm-mark path,
.gm-app[data-gm-vision="contrast"] .gm-mark circle {
  stroke: #000;
  stroke-width: 2;
}

.gm-app .gm-mama { font-size: calc(16px * var(--gm-scale)); line-height: 1.74; min-width: 0; color: var(--gm-ink); }
.gm-app .gm-mama p { margin: 0 0 14px !important; line-height: 1.74; }
.gm-app .gm-mama p:last-child { margin-bottom: 0 !important; }
.gm-app .gm-mama strong { font-weight: 700; color: var(--gm-ink); }
.gm-app .gm-mama a { color: var(--gm-rust); text-decoration: underline; text-underline-offset: 3px; }
.gm-app .gm-mama a:hover { color: var(--gm-orange); }

.gm-app .gm-mama ol { margin: 0 0 14px !important; padding-left: 0 !important; counter-reset: gmn; }
.gm-app .gm-mama ol li {
  counter-increment: gmn;
  position: relative; padding-left: 30px; margin-bottom: 11px; line-height: 1.7;
}
.gm-app .gm-mama ol li::before {
  content: counter(gmn);
  position: absolute; left: 0; top: 4px;
  width: 21px; height: 21px; border-radius: 6px;
  background: var(--gm-raise); color: var(--gm-ink-2);
  font-size: 11.5px; font-weight: 700;
  display: grid; place-items: center; line-height: 1;
}

.gm-app .gm-bubble {
  background: var(--gm-navy);
  color: #F2F5F6;
  border-radius: 16px 16px 5px 16px;
  padding: 11px 16px;
  font-size: calc(14.5px * var(--gm-scale)); font-weight: 500;
  max-width: 72%;
  line-height: 1.6;
}

.gm-app .gm-think { display: flex; align-items: center; gap: 11px; }
.gm-app .gm-think-lb { color: var(--gm-muted); font-size: 15px; font-weight: 500; }
.gm-app .gm-dots { display: inline-flex; gap: 5px; }
.gm-app .gm-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--gm-orange); display: block; animation: gmBob 1.2s ease-in-out infinite; }
.gm-app .gm-dots i:nth-child(2) { animation-delay: .16s; }
.gm-app .gm-dots i:nth-child(3) { animation-delay: .32s; }
@keyframes gmBob { 0%,60%,100% { opacity: .25; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-4px); } }

/* read-in-place chips */

.gm-app .gm-reads { margin-top: 16px; border-top: 1px solid var(--gm-line-2); padding-top: 13px; }
.gm-app .gm-reads-h {
  font-size: 10px; letter-spacing: .1em; text-transform: uppercase !important;
  color: var(--gm-muted); font-weight: 700; margin-bottom: 9px;
}
.gm-app .gm-read {
  display: flex; align-items: center; gap: 9px;
  width: 100%;
  border: 1px solid var(--gm-line) !important;
  border-radius: 10px; padding: 10px 13px; margin-bottom: 7px;
  font-size: 13.5px; font-weight: 500; color: var(--gm-ink);
  transition: border-color .15s ease, background .15s ease;
}
.gm-app .gm-read:hover { border-color: var(--gm-orange) !important; background: var(--gm-tint); }
.gm-app .gm-read svg { color: var(--gm-muted); }
.gm-app .gm-read:hover svg { color: var(--gm-orange); }

/* ===================== composer ===================== */

.gm-app .gm-foot { padding: 12px 22px 18px; }
.gm-app .gm-foot-in { max-width: 700px; margin: 0 auto; }

.gm-app .gm-comp {
  display: flex; align-items: flex-end; gap: 8px;
  background: var(--gm-surface);
  border: 1.5px solid var(--gm-line);
  border-radius: 18px;
  padding: 8px 8px 8px 17px;
  transition: border-color .18s ease, box-shadow .18s ease;
}
.gm-app .gm-comp:focus-within { border-color: var(--gm-orange); box-shadow: 0 0 0 4px rgba(232,84,43,.1); }

.gm-app .gm-comp textarea {
  flex: 1; min-width: 0;
  border: 0 !important; outline: 0; resize: none; background: transparent;
  color: var(--gm-ink);
  font-family: var(--gm-ui) !important;
  font-size: calc(15.5px * var(--gm-scale)) !important;
  line-height: 1.55 !important; font-weight: 500;
  max-height: 150px; padding: 6px 0 !important;
  box-shadow: none !important;
}
.gm-app .gm-comp textarea::placeholder { color: var(--gm-muted); font-weight: 400; }

.gm-app .gm-cb {
  flex: none; width: 38px; height: 38px;
  border-radius: 11px;
  background: var(--gm-raise); color: var(--gm-ink-2);
  display: grid; place-items: center;
  transition: background .15s ease, color .15s ease;
}
.gm-app .gm-cb:hover { background: var(--gm-tint); color: var(--gm-orange); }
.gm-app .gm-cb[disabled] { opacity: .4; cursor: default; }
.gm-app .gm-cb[disabled]:hover { background: var(--gm-raise); color: var(--gm-ink-2); }

.gm-cb.gm-live { background: var(--gm-orange); color: #fff; }
.gm-cb.gm-live svg { animation: gmPulse 1.1s ease-in-out infinite; }
@keyframes gmPulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.14); } }

.gm-go { background: var(--gm-navy); color: #fff; }
.gm-go:hover { background: var(--gm-orange); color: #fff; }

/* ---------- the three ways in ----------

   These only have a job on an empty conversation. Once someone
   has started talking they are three stray tags sitting under
   the reply, so they go.                                       */

.gm-app .gm-starts {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 14px;
}

.gm-app .gm-starts[hidden] { display: none; }

.gm-app .gm-starts-lb {
  width: 100%;
  margin-bottom: 2px;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--gm-muted);
  text-align: center;
}

.gm-app .gm-starts button {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 17px;
  border: 1px solid var(--gm-line);
  border-radius: 999px;
  background: var(--gm-surface);
  font-family: var(--gm-ui);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  text-transform: none;
  letter-spacing: normal;
  color: var(--gm-ink-2);
  cursor: pointer;
  transition: border-color .15s ease, color .15s ease, background .15s ease,
              transform .15s ease, box-shadow .15s ease;
}

.gm-app .gm-starts button:hover {
  border-color: var(--gm-orange);
  color: var(--gm-ink);
  background: var(--gm-surface);
  transform: translateY(-1px);
  box-shadow: 0 3px 12px rgba(232, 84, 43, 0.13);
}

.gm-app .gm-starts button:active { transform: translateY(0); box-shadow: none; }

/* The same three shapes the perspective chips use: square for
   legal, diamond for financial, circle for wellness. Colour says
   the same thing twice rather than carrying it alone, so these
   still read with no colour vision at all. */
.gm-app .gm-pip {
  width: 9px;
  height: 9px;
  flex: none;
  background: currentColor;
}

.gm-app .gm-pip-l { border-radius: 2px; color: var(--gm-legal); }
.gm-app .gm-pip-f { border-radius: 2px; color: var(--gm-fin); transform: rotate(45deg) scale(0.9); }
.gm-app .gm-pip-w { border-radius: 50%; color: var(--gm-well); }

/* The three openers about the article itself are not one of the
   three lenses, so they get a shape of their own rather than
   borrowing a meaning they do not have. */
.gm-app .gm-pip-t {
  border-radius: 50%;
  color: var(--gm-muted, #8C9398);
  background: none;
  box-shadow: inset 0 0 0 2px currentColor;
}

.gm-app .gm-note {
  font-size: 11.5px; color: var(--gm-muted); text-align: center;
  line-height: 1.6; margin: 13px auto 0 !important; max-width: 580px; font-weight: 500;
}

/* ===================== settings drawer ===================== */

.gm-app .gm-drawer {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: 320px; max-width: 86%;
  background: var(--gm-surface);
  border-left: 1px solid var(--gm-line);
  z-index: 20;
  transform: translateX(100%);
  transition: transform .24s ease;
  display: flex; flex-direction: column;
  box-shadow: -14px 0 40px -26px rgba(21,24,26,.4);
}
.gm-app.gm-full .gm-drawer { position: fixed; z-index: 99993; }
.gm-drawer.gm-open { transform: none; }

.gm-app .gm-drawer-top {
  display: flex; align-items: center; gap: 10px;
  padding: 15px 18px; border-bottom: 1px solid var(--gm-line-2);
}
.gm-app .gm-drawer-top h3 { font-size: 14.5px !important; font-weight: 700 !important; flex: 1; margin: 0 !important; }
.gm-app .gm-drawer-x { color: var(--gm-muted); padding: 4px; border-radius: 7px; line-height: 0; }
.gm-app .gm-drawer-x:hover { color: var(--gm-orange); }

.gm-app .gm-drawer-body { flex: 1; overflow-y: auto; padding: 18px; }

.gm-field { margin-bottom: 22px; }
.gm-app .gm-field-h { font-size: 12.5px; font-weight: 700; color: var(--gm-ink); margin-bottom: 4px; }
.gm-app .gm-field-s { font-size: 11.5px; color: var(--gm-muted); line-height: 1.5; margin-bottom: 10px; font-weight: 500; }

.gm-app .gm-seg { display: flex; gap: 6px; flex-wrap: wrap; }
.gm-app .gm-seg button {
  flex: 1; min-width: 84px;
  border: 1px solid var(--gm-line) !important;
  border-radius: 9px; padding: 8px 6px;
  font-size: 12.5px; font-weight: 600; color: var(--gm-ink-2);
  text-align: center;
  transition: border-color .15s ease, background .15s ease, color .15s ease;
}
.gm-app .gm-seg button:hover { border-color: var(--gm-orange) !important; color: var(--gm-orange); }
.gm-app .gm-seg button[aria-pressed="true"] {
  background: var(--gm-navy) !important; border-color: var(--gm-navy) !important; color: #fff;
}

.gm-app .gm-switch {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  width: 100%; padding: 11px 4px;
  border-top: 1px solid var(--gm-line-2) !important;
  font-size: 13.5px; font-weight: 600; color: var(--gm-ink);
  border-radius: 8px;
  transition: color .14s ease;
}
.gm-app .gm-switch:hover { background: none; color: var(--gm-orange); }
.gm-app .gm-switch:hover .gm-switch-track { background: #D9D6D1; }
.gm-app .gm-switch[aria-pressed="true"]:hover .gm-switch-track { background: var(--gm-rust); }
.gm-app .gm-switch-track {
  width: 40px; height: 23px; border-radius: 999px; flex: none;
  background: var(--gm-line); position: relative; transition: background .16s ease;
}
.gm-app .gm-switch-track::after {
  content: ""; position: absolute; top: 3px; left: 3px;
  width: 17px; height: 17px; border-radius: 50%; background: #fff;
  transition: transform .16s ease;
  box-shadow: 0 1px 2px rgba(21,24,26,.25);
}
.gm-app .gm-switch[aria-pressed="true"] .gm-switch-track { background: var(--gm-orange); }
.gm-app .gm-switch[aria-pressed="true"] .gm-switch-track::after { transform: translateX(17px); }

.gm-app .gm-drawer-foot {
  border-top: 1px solid var(--gm-line-2);
  padding: 13px 18px;
  font-size: 11.5px; color: var(--gm-muted); line-height: 1.5; font-weight: 500;
}

/* ===================== modal ===================== */

.gm-modal {
  position: fixed; inset: 0; z-index: 99996;
  background: rgba(21,24,26,.5);
  display: flex; align-items: center; justify-content: center;
  padding: 24px 16px;
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
}
.gm-modal[hidden] { display: none; }

.gm-modal-card {
  background: #fff; border-radius: 16px;
  width: min(760px, 100%); max-height: min(84vh, 900px);
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 30px 70px -24px rgba(10,20,26,.5);
}
.gm-modal-card.gm-sm { width: min(430px, 100%); }

.gm-modal-top { display: flex; align-items: center; gap: 14px; padding: 16px 20px; border-bottom: 1px solid #E8E6E2; }
.gm-modal-top h3 {
  margin: 0 !important; flex: 1; min-width: 0;
  font-size: 16px !important; font-weight: 700 !important; color: #15181A;
  text-transform: none !important; letter-spacing: normal !important;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.gm-modal-open { font-size: 13px; font-weight: 600; color: #C4502B; text-decoration: none; white-space: nowrap; }
.gm-modal-open:hover { text-decoration: underline; }
.gm-modal-x { border: 0; background: none; color: #8C9398; padding: 4px; border-radius: 7px; line-height: 0; cursor: pointer; }
.gm-modal-x:hover { color: #E8542B; }

.gm-modal-body { overflow-y: auto; padding: 22px 26px 30px; font-size: 16px; line-height: 1.75; color: #333C42; }
.gm-modal-body h1, .gm-modal-body h2, .gm-modal-body h3 { color: #15232B; line-height: 1.3; margin: 26px 0 12px; }
.gm-modal-body img { max-width: 100%; height: auto; border-radius: 10px; }
.gm-modal-body a { color: #C4502B; }
.gm-modal-body p { margin: 0 0 16px; }
.gm-modal-loading { color: #8C9398; font-size: 14px; }

/* coming-soon card */

.gm-soon-body { padding: 26px 26px 28px; text-align: center; }
.gm-soon-ico {
  width: 54px; height: 54px; border-radius: 16px; margin: 0 auto 16px;
  background: #FDEFE9; color: #E8542B; display: grid; place-items: center;
}
.gm-soon-body h4 { margin: 0 0 8px; font-size: 17px; font-weight: 700; color: #15181A; }
.gm-soon-body p { margin: 0 0 6px; font-size: 14.5px; line-height: 1.65; color: #4A5257; }
.gm-soon-tag {
  display: inline-block; margin-top: 14px;
  background: #F5F4F2; color: #8C9398;
  font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  border-radius: 6px; padding: 5px 11px;
}

/* ===================== responsive ===================== */

.gm-scrim { position: fixed; inset: 0; background: rgba(21,24,26,.35); z-index: 99991; }

@media (max-width: 980px) {
  .gm-app { grid-template-columns: minmax(0, 1fr); }

  .gm-app .gm-side {
    position: absolute; inset: 0 auto 0 0; width: 272px; z-index: 30;
    background: var(--gm-surface);
    transform: translateX(-100%); transition: transform .24s ease;
    box-shadow: 14px 0 40px -26px rgba(21,24,26,.4);
  }
  .gm-app.gm-full .gm-side { position: fixed; z-index: 99992; padding-top: calc(18px + env(safe-area-inset-top, 0px)); }
  .gm-side.gm-open { transform: none; }

  .gm-app .gm-ghost { display: block; }
  .gm-app .gm-tbtn .gm-lbl { display: none; }
  .gm-app .gm-tbtn { padding: 7px 9px; }
}

@media (max-width: 640px) {
  .gm-app { --gm-height: 86vh; border-radius: 12px; }
  .gm-app .gm-stream, .gm-app .gm-foot, .gm-app .gm-top { padding-left: 14px; padding-right: 14px; }
  .gm-app .gm-bubble { max-width: 88%; }
  .gm-app .gm-inner { max-width: 100%; }
  .gm-app .gm-soon { display: none; }
  .gm-modal-body { padding: 18px 18px 24px; font-size: 15px; }
  /* Wrapping three long pills on a phone makes a ragged block.
     One row that scrolls keeps the shape of the thing. */
  .gm-app .gm-starts {
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 7px;
    overflow-x: auto;
    padding: 2px 16px 4px;
    margin-left: -16px;
    margin-right: -16px;
    scrollbar-width: none;
  }

  .gm-app .gm-starts::-webkit-scrollbar { display: none; }

  .gm-app .gm-starts-lb { display: none; }

  .gm-app .gm-starts button {
    flex: 0 0 auto;
    padding: 9px 14px;
    font-size: 12.5px;
  }
}

@media (max-width: 420px) {
  .gm-app .gm-top { gap: 6px; padding-left: 12px; padding-right: 12px; }
  .gm-app .gm-title { font-size: 14px !important; }
  .gm-app .gm-cb { width: 36px; height: 36px; }
}

@media (prefers-reduced-motion: reduce) {
  .gm-app *, .gm-modal * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .gm-app .gm-stream { scroll-behavior: auto; }
}

/* ==========================================================
   Provider listings and chips

   Every selector carries .gm-app. The theme styles button and
   a globally, and a bare .gm-chip loses to button:hover.
   ========================================================== */

.gm-app .gm-prov {
  margin: 14px 0 2px;
  display: grid;
  gap: 8px;
}

.gm-app .gm-prov-note {
  font-size: 0.92em;
  color: var(--gm-ink-2);
  line-height: 1.55;
  margin: 0;
  padding: 10px 12px;
  background: var(--gm-raise);
  border-radius: 10px;
}

.gm-app .gm-pv {
  border: 1px solid var(--gm-line);
  border-radius: 12px;
  padding: 12px 14px;
  background: var(--gm-surface);
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.gm-app .gm-pv:hover {
  border-color: var(--gm-orange);
  box-shadow: 0 1px 10px rgba(232, 84, 43, 0.08);
}

.gm-app .gm-pv-name {
  font-weight: 600;
  font-size: 1em;
  line-height: 1.35;
  color: var(--gm-ink);
  margin: 0 0 3px;
}

.gm-app .gm-pv-addr {
  font-size: 0.9em;
  color: var(--gm-ink-2);
  line-height: 1.5;
  margin: 0;
}

.gm-app .gm-pv-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 8px;
}

.gm-app a.gm-pv-link {
  font-size: 0.88em;
  font-weight: 500;
  color: var(--gm-ink);
  text-decoration: none;
  border-bottom: 1px solid var(--gm-line);
  padding-bottom: 1px;
  transition: color 0.14s ease, border-color 0.14s ease;
}

.gm-app a.gm-pv-link:hover {
  color: var(--gm-orange);
  border-bottom-color: var(--gm-orange);
}

.gm-app .gm-pv-km {
  font-size: 0.82em;
  color: var(--gm-muted);
  margin-left: auto;
}

.gm-app .gm-prov-foot {
  font-size: 0.8em;
  color: var(--gm-muted);
  line-height: 1.5;
  margin-top: 2px;
}

/* ---------- chips ---------- */

.gm-app .gm-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 2px;
}

.gm-app button.gm-chip {
  font-family: var(--gm-ui);
  font-size: 0.89em;
  font-weight: 500;
  line-height: 1.2;
  text-transform: none;
  letter-spacing: normal;
  padding: 8px 16px;
  border: 1px solid var(--gm-line);
  border-radius: 999px;
  background: var(--gm-surface);
  color: var(--gm-ink);
  cursor: pointer;
  transition: border-color 0.14s ease, color 0.14s ease, background 0.14s ease;
}

.gm-app button.gm-chip:hover {
  border-color: var(--gm-orange);
  color: var(--gm-orange);
  background: var(--gm-surface);
}

/* The chosen one stays filled, the others fade but remain.
   The reader can see the path they took. */
.gm-app button.gm-chip.gm-chip-on,
.gm-app button.gm-chip.gm-chip-on:hover {
  background: var(--gm-orange);
  border-color: var(--gm-orange);
  color: #fff;
  cursor: default;
}

.gm-app button.gm-chip.gm-chip-off,
.gm-app button.gm-chip.gm-chip-off:hover {
  opacity: 0.45;
  border-color: var(--gm-line);
  color: var(--gm-ink-2);
  background: var(--gm-surface);
  cursor: default;
}

/* A quiet tint per domain so the three perspectives are
   distinguishable at a glance before any is chosen. */

@media (max-width: 560px) {
  .gm-app .gm-pv-km { margin-left: 0; width: 100%; }
  .gm-app .gm-chips { gap: 6px; }
  .gm-app button.gm-chip { padding: 7px 13px; font-size: 0.86em; }
}

/* ==========================================================
   Colour settings

   Colour is decoration here, never the message. Each
   perspective chip carries its own written label and a shape
   marker, so these options change how the interface looks
   without changing what it says.
   ========================================================== */

/* A palette that stays separable under the three common kinds of
   colour blindness: blue, amber and violet differ in lightness as
   well as hue, so they remain distinct even in greyscale. */
.gm-app[data-gm-vision="safe"] {
  --gm-legal: #2B6CB0;
  --gm-fin:   #B7791F;
  --gm-well:  #6B46C1;
  --gm-orange: #0B64C4;
  --gm-rust:   #0B4F99;
  --gm-tint:   #E7F0FB;
}

.gm-app[data-gm-vision="contrast"] {
  --gm-legal:   #000000;
  --gm-fin:     #000000;
  --gm-well:    #000000;
  --gm-orange:  #000000;
  --gm-rust:    #000000;
  --gm-tint:    #FFFFFF;
  --gm-ink:     #000000;
  --gm-ink-2:   #1A1A1A;
  --gm-muted:   #3A3A3A;
  --gm-line:    #000000;
  --gm-line-2:  #767676;
  --gm-raise:   #FFFFFF;
}

.gm-app[data-gm-vision="contrast"] button.gm-chip.gm-chip-on,
.gm-app[data-gm-vision="contrast"] button.gm-chip.gm-chip-on:hover {
  background: #000;
  color: #fff;
}

.gm-app[data-gm-vision="contrast"] button.gm-chip.gm-chip-off {
  opacity: 1;
  color: #3A3A3A;
  border-style: dashed;
}

.gm-app[data-gm-vision="contrast"] .gm-pv:hover,
.gm-app[data-gm-vision="contrast"] a.gm-pv-link:hover {
  outline: 2px solid #000;
  outline-offset: 1px;
}

/* The shape marker. This is what makes the three perspectives
   tellable apart with no colour vision at all, and it is present
   in every mode rather than switched on by a setting, because a
   reader who needs it should not have to find it first. */
.gm-app button.gm-chip-legal::before,
.gm-app button.gm-chip-fin::before,
.gm-app button.gm-chip-well::before {
  content: '';
  display: inline-block;
  width: 9px;
  height: 9px;
  margin-right: 8px;
  vertical-align: baseline;
  background: currentColor;
}

/* square, diamond, circle */
.gm-app button.gm-chip-legal::before { border-radius: 2px; }
.gm-app button.gm-chip-fin::before   { border-radius: 2px; transform: rotate(45deg) scale(0.9); }
.gm-app button.gm-chip-well::before  { border-radius: 50%; }

.gm-app button.gm-chip-legal:not(.gm-chip-on):not(.gm-chip-off)::before { color: var(--gm-legal); }
.gm-app button.gm-chip-fin:not(.gm-chip-on):not(.gm-chip-off)::before   { color: var(--gm-fin); }
.gm-app button.gm-chip-well:not(.gm-chip-on):not(.gm-chip-off)::before  { color: var(--gm-well); }

/* ==========================================================
   Reading an article
   ========================================================== */

.gm-read-ctl {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  margin-right: 10px;
}

.gm-read-ctl button {
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  text-transform: none;
  letter-spacing: normal;
  width: 30px;
  height: 28px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 1px;
  border: 1px solid #E8E6E2;
  border-radius: 7px;
  background: #FFFFFF;
  color: #4A5257;
  cursor: pointer;
}

.gm-read-ctl button span { font-size: 9px; }

.gm-read-ctl button:hover {
  border-color: #E8542B;
  color: #E8542B;
}

.gm-read-ctl button[aria-pressed="true"] {
  border-color: #15181A;
  box-shadow: inset 0 0 0 1px #15181A;
}

.gm-read-sep {
  width: 1px;
  height: 18px;
  background: #E8E6E2;
  margin: 0 4px;
}

.gm-swatch {
  width: 13px;
  height: 13px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.22);
  display: block;
}

.gm-sw-paper { background: #FFFFFF; }
.gm-sw-sepia { background: #F3E7D2; }
.gm-sw-night { background: #1A1D20; }

/* The page itself. A measure of about 68 characters, a serif, and
   generous leading, because these articles are long and someone
   in trouble reads them end to end. */
.gm-modal-card[data-gm-page] { --gm-read: 1; }

.gm-modal-card[data-gm-page] .gm-modal-body {
  font-family: "Playfair Display", Georgia, serif;
  font-size: calc(17px * var(--gm-read));
  line-height: 1.75;
  letter-spacing: 0.002em;
}

.gm-modal-card[data-gm-page] .gm-modal-body > * {
  max-width: 68ch;
  margin-left: auto;
  margin-right: auto;
}

.gm-modal-card[data-gm-page] .gm-modal-body p {
  margin: 0 0 1.15em;
}

.gm-modal-card[data-gm-page] .gm-modal-body h2,
.gm-modal-card[data-gm-page] .gm-modal-body h3,
.gm-modal-card[data-gm-page] .gm-modal-body h4 {
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
  line-height: 1.3;
  margin: 1.8em 0 0.6em;
}

.gm-modal-card[data-gm-page] .gm-modal-body h2 { font-size: calc(21px * var(--gm-read)); }
.gm-modal-card[data-gm-page] .gm-modal-body h3 { font-size: calc(18px * var(--gm-read)); }

.gm-modal-card[data-gm-page] .gm-modal-body img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.gm-modal-card[data-gm-page="paper"] .gm-modal-body {
  background: #FFFFFF;
  color: #1A1D20;
}

.gm-modal-card[data-gm-page="sepia"] .gm-modal-body {
  background: #F6EBD8;
  color: #3A2F22;
}

.gm-modal-card[data-gm-page="sepia"] .gm-modal-body a { color: #8A4B1F; }

.gm-modal-card[data-gm-page="night"] .gm-modal-body {
  background: #16191C;
  color: #D8DCE0;
}

.gm-modal-card[data-gm-page="night"] .gm-modal-body a { color: #F0875F; }

.gm-modal-card[data-gm-page="night"] .gm-modal-body h2,
.gm-modal-card[data-gm-page="night"] .gm-modal-body h3,
.gm-modal-card[data-gm-page="night"] .gm-modal-body h4 { color: #F2F4F6; }

/* ==========================================================
   Talking with Mama
   ========================================================== */

.gm-talk {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(10, 13, 16, 0.72);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
  box-sizing: border-box;
}

.gm-talk[hidden] { display: none; }

.gm-talk *, .gm-talk *::before, .gm-talk *::after { box-sizing: border-box; }

.gm-talk-card {
  position: relative;
  width: 100%;
  max-width: 430px;
  padding: 44px 30px 30px;
  border-radius: 22px;
  background: #15181A;
  color: #F2F4F6;
  text-align: center;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
}

.gm-talk-x {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px;
  height: 34px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #8C9398;
  cursor: pointer;
}

.gm-talk-x:hover { color: #fff; background: rgba(255, 255, 255, 0.08); }

/* Three bars that move while she listens and while she speaks,
   and hold still while she thinks. The reader can tell which of
   the three is happening without reading the label. */
.gm-orb {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 7px;
  height: 56px;
  margin-bottom: 18px;
}

.gm-orb span {
  width: 9px;
  height: 14px;
  border-radius: 999px;
  background: #E8542B;
  transform-origin: bottom center;
}

.gm-talk[data-gm-mode="listening"] .gm-orb span { animation: gm-bar 1.05s ease-in-out infinite; }
.gm-talk[data-gm-mode="speaking"]  .gm-orb span { animation: gm-bar 0.62s ease-in-out infinite; background: #F2F4F6; }

.gm-talk[data-gm-mode="thinking"] .gm-orb span { opacity: 0.4; animation: gm-pulse 1.5s ease-in-out infinite; }
.gm-talk[data-gm-mode="paused"]   .gm-orb span { opacity: 0.28; }

.gm-talk[data-gm-mode="microphone blocked"] .gm-orb span,
.gm-talk[data-gm-mode="voice unavailable"] .gm-orb span,
.gm-talk[data-gm-mode="no microphone"] .gm-orb span {
  opacity: 0.3;
  background: #8C9398;
  height: 14px;
}

.gm-orb span:nth-child(2) { animation-delay: 0.16s; }
.gm-orb span:nth-child(3) { animation-delay: 0.32s; }

@keyframes gm-bar {
  0%, 100% { height: 14px; }
  50%      { height: 42px; }
}

@keyframes gm-pulse {
  0%, 100% { opacity: 0.25; }
  50%      { opacity: 0.6; }
}

@media (prefers-reduced-motion: reduce) {
  .gm-orb span { animation: none !important; height: 22px; }
}

.gm-talk-state {
  margin: 0 0 10px;
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #F2F4F6;
}

.gm-talk-live {
  min-height: 48px;
  margin: 0 0 22px;
  font-size: 15px;
  line-height: 1.55;
  color: #A8B0B6;
}

.gm-talk-acts {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-bottom: 18px;
}

.gm-talk-btn {
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  text-transform: none;
  letter-spacing: normal;
  padding: 12px 24px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: transparent;
  color: #F2F4F6;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.gm-talk-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.4);
}

.gm-talk-btn.gm-talk-end {
  background: #E8542B;
  border-color: #E8542B;
}

.gm-talk-btn.gm-talk-end:hover { background: #C4502B; border-color: #C4502B; }

.gm-talk-note {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.5;
  color: #6F777D;
}

@media (max-width: 480px) {
  .gm-talk-card { padding: 40px 20px 24px; }
  .gm-app .gm-read-ctl { margin-right: 6px; gap: 3px; }
  .gm-app .gm-read-ctl button { width: 27px; height: 26px; }
}

/* ---------- the voice picker ---------- */

.gm-app select.gm-select {
  width: 100%;
  font-family: var(--gm-ui);
  font-size: 0.92em;
  line-height: 1.3;
  text-transform: none;
  letter-spacing: normal;
  padding: 10px 34px 10px 13px;
  margin-top: 4px;
  border: 1px solid var(--gm-line);
  border-radius: 10px;
  background-color: var(--gm-surface);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238C9398' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  color: var(--gm-ink);
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.gm-app select.gm-select:hover { border-color: var(--gm-orange); }
.gm-app select.gm-select:focus-visible { outline: 2px solid var(--gm-orange); outline-offset: 1px; }

/* The overlay sits outside .gm-app, so its interrupt hint carries
   its own colour rather than inheriting one that never arrives. */
.gm-talk-hint {
  margin: 0 0 14px;
  font-size: 12.5px;
  line-height: 1.5;
  color: #6F777D;
}

/* The voice field needs to look like something you can act on.
   A grey caret on a quiet row is easy to read past, so the row
   underneath says how many voices there are and offers a listen
   without first having to change the selection. */
.gm-app .gm-voice-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.gm-app .gm-voice-row .gm-field-s { margin: 0; }

.gm-app button.gm-mini {
  font-family: var(--gm-ui);
  font-size: 0.82em;
  line-height: 1.2;
  text-transform: none;
  letter-spacing: normal;
  padding: 7px 12px;
  border: 1px solid var(--gm-line);
  border-radius: 999px;
  background: var(--gm-surface);
  color: var(--gm-ink);
  cursor: pointer;
  white-space: nowrap;
}

.gm-app button.gm-mini:hover { border-color: var(--gm-orange); color: var(--gm-orange); }
.gm-app button.gm-mini:focus-visible { outline: 2px solid var(--gm-orange); outline-offset: 1px; }

/* When the directory comes back empty the reader still needs a
   way to reach a lawyer, so the fallback routes are given the
   same weight as a result rather than the look of an error. */
.gm-app .gm-prov-routes {
  margin-top: 10px;
  padding: 12px 14px;
  border: 1px solid var(--gm-line);
  border-radius: 12px;
  background: var(--gm-surface);
}

.gm-app .gm-prov-routes-h {
  font-family: var(--gm-ui);
  font-size: 0.82em;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--gm-muted, #6F777D);
  margin-bottom: 8px;
}

.gm-app .gm-prov-routes ul {
  margin: 0;
  padding-left: 18px;
}

.gm-app .gm-prov-routes li {
  margin: 0 0 8px;
  line-height: 1.55;
}

.gm-app .gm-prov-routes li:last-child { margin-bottom: 0; }

/* ==========================================================
   The way out of an article, on a phone

   Henry opened an article on his phone and could not close it:
   no X in reach and no back arrow. The header packs a title,
   two text-size buttons, three page-colour buttons, a link and
   a close button into one row, and on a narrow screen the X is
   the thing pushed off the edge.

   So on a phone the panel fills the screen, the header sticks
   to the top and wraps, and the X is guaranteed a place on the
   first row at a size a thumb can hit.
   ========================================================== */

.gm-modal-foot {
  margin: 28px 0 4px;
  padding-top: 20px;
  border-top: 1px solid #E8E6E2;
  text-align: center;
}

.gm-modal-back {
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
  font-size: 15px;
  font-weight: 600;
  padding: 12px 20px;
  min-height: 44px;
  border: 1px solid #DFE3E6;
  border-radius: 999px;
  background: #fff;
  color: #1D3C4A;
  cursor: pointer;
}

.gm-modal-back:hover { border-color: #E8542B; color: #C4502B; }
.gm-modal-back:focus-visible { outline: 2px solid #E8542B; outline-offset: 1px; }

@media (max-width: 640px) {
  .gm-modal { padding: 0; align-items: stretch; }

  .gm-modal-card {
    width: 100%;
    max-height: 100%;
    height: 100%;
    border-radius: 0;
  }

  .gm-modal-top {
    flex-wrap: wrap;
    row-gap: 10px;
    position: sticky;
    top: 0;
    z-index: 2;
    background: #fff;
    padding: 12px 14px;
  }

  /* The title and the X share the first row, and the X is never
     the one that gives way. */
  .gm-modal-top h3 {
    flex: 1 1 auto;
    order: 1;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    font-size: 15px !important;
    line-height: 1.3;
  }

  .gm-modal-x {
    order: 2;
    flex: 0 0 auto;
    margin-left: auto;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #15232B;
  }

  .gm-modal-card .gm-read-ctl { order: 3; flex: 1 1 100%; }
  .gm-modal-open { order: 4; flex: 0 0 auto; }
}

/* "Mama is searching" — the lookup can run for several seconds
   when the directory is slow, and a still line of text reads as
   nothing happening. The dots reuse the thinking animation, so
   waiting for an answer and waiting for a lookup look the same. */
.gm-app .gm-prov-wait {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 2px 0 2px;
}

.gm-app .gm-prov-dots { display: inline-flex; gap: 5px; flex: none; }

.gm-app .gm-prov-dots i {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--gm-orange); display: block;
  animation: gmBob 1.2s ease-in-out infinite;
}

.gm-app .gm-prov-dots i:nth-child(2) { animation-delay: .16s; }
.gm-app .gm-prov-dots i:nth-child(3) { animation-delay: .32s; }

.gm-app .gm-prov-wait-lb {
  font-size: 13.5px;
  color: var(--gm-muted, #6F777D);
  line-height: 1.5;
}

/* ==========================================================
   The header on a phone

   Henry on an iPhone 11: "The header that contains the Mamas
   menu bars-settings seem small and hard to read. Is this
   because we are trying to fit too much on a Mobile screen?"

   Yes. Three labelled buttons, a title and a menu in one row
   at 390px leaves nothing room to be legible. So the labels go
   and the buttons become proper touch targets instead of
   shrinking the text to fit.
   ========================================================== */

@media (max-width: 640px) {
  .gm-app .gm-top {
    gap: 8px;
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .gm-app .gm-tbtn {
    min-width: 42px;
    min-height: 42px;
    padding: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .gm-app .gm-tbtn svg { width: 18px; height: 18px; }

  /* The conversation title was shrinking to make room. It can
     have the room instead. */
  .gm-app .gm-top .gm-title {
    font-size: 15px !important;
    line-height: 1.3;
  }
}
