/* Hangout - the video-call screen after a call is answered (fe/hangout.js).
   Dark, Meet/Hangouts-style: a stage with tiles, captions, a control bar. */
.in-hangout #voiceCallOverlay { display: none !important; }

.ho {
  --ho-bg: #202124;
  --ho-tile: #3c4043;
  --ho-text: #e8eaed;
  --ho-dim: #9aa0a6;
  --ho-accent: #8ab4f8;
  --ho-red: #ea4335;
  /* the small corner tiles - yours, and WhackGPT's while it presents -
     share one size so they match */
  --ho-pip-w: min(30vw, 180px);
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: none;
  flex-direction: column;
  background: var(--ho-bg);
  color: var(--ho-text);
  font-family: "Google Sans", Roboto, system-ui, sans-serif;
}
.in-hangout .ho { display: flex; }

.ho-top {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  font-size: 15px;
}
.ho-title { font-weight: 500; }
.ho-dot, .ho-timer { color: var(--ho-dim); }
/* "things to try" trigger, up in the header next to REC - opens the lightbox */
.ho-tips-btn {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  color: var(--ho-dim);
  font-size: 11px;
  letter-spacing: 0.02em;
  cursor: pointer;
}
.ho-tips-btn:hover { background: rgba(255, 255, 255, 0.14); color: #fff; }
.ho-tips-btn i { font-size: 10px; }
.ho-rec {
  font-size: 12px;
  color: var(--ho-red);
  letter-spacing: 0.05em;
}
.ho-rec i { font-size: 9px; animation: ho-blink 1.4s infinite; }
@keyframes ho-blink { 50% { opacity: 0.2; } }

/* ---- stage ---- */
.ho-stage {
  position: relative;
  flex: 1;
  min-height: 0;
  margin: 0 16px;
}
.ho-tile {
  position: absolute;
  background: var(--ho-tile);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 0 transparent;
  transition: all 0.35s ease, box-shadow 0.15s;
}
.ho-name {
  position: absolute;
  left: 10px;
  bottom: 8px;
  font-size: 13px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
}
.ho-mic { font-size: 11px; margin-left: 4px; color: var(--ho-dim); }

/* WhackGPT: the whole stage, until it presents something */
.ho-ai { inset: 0; }
.ho-face {
  width: min(40vw, 40vh, 220px);
  aspect-ratio: 1;
  border-radius: 50%;
  object-fit: cover;
}
.ho.ai-speaking .ho-ai { box-shadow: 0 0 0 3px var(--ho-accent); }
.ho.ai-speaking .ho-ai .ho-face { animation: ho-talk 0.5s ease-in-out infinite alternate; }
.ho.ai-speaking .ho-ai .ho-mic { color: var(--ho-accent); }
@keyframes ho-talk { to { transform: scale(1.04); } }

/* you: a small self-view in the corner */
.ho-me {
  right: 12px;
  bottom: 12px;
  width: var(--ho-pip-w);
  aspect-ratio: 4 / 3;
  background: #5f6368;
  z-index: 2;
}
.ho-initial {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #7e57c2;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 500;
}
.ho.me-speaking .ho-me { box-shadow: 0 0 0 3px var(--ho-accent); }
.ho.me-muted .ho-me .ho-mic::before { content: "\f131"; color: var(--ho-red); }

/* ---- presenting: the shared screen takes the stage, the face shrinks ---- */
.ho-present {
  position: absolute;
  inset: 0;
  display: none;
  flex-direction: column;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
}
.ho.presenting .ho-present { display: flex; }
.ho.presenting .ho-ai {
  inset: 12px 12px auto auto;
  width: var(--ho-pip-w);
  height: auto;
  aspect-ratio: 4 / 3;
  z-index: 2;
}
.ho.presenting .ho-ai .ho-face { width: auto; height: 62%; }
.ho-initial { height: 62%; width: auto; aspect-ratio: 1; }
.ho-present-label {
  padding: 8px 12px;
  font-size: 13px;
  color: var(--ho-dim);
  background: rgba(255, 255, 255, 0.06);
}
.ho-present-body {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  overflow: auto;
}
.ho-present-body img,
.ho-present-body .svg-drawing,
.ho-svg {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.ho-svg, .ho-present-body .svg-drawing { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.ho-svg svg, .ho-present-body .svg-img { max-width: 100%; max-height: 100%; width: auto; height: 100%; }
.ho-pending { max-width: 60%; max-height: 60%; opacity: 0.85; }
.ho-present-body:has(.ho-code) { align-items: stretch; justify-content: flex-start; flex-direction: column; }
.ho-code-lang { font-size: 12px; color: var(--ho-dim); padding: 0 4px 6px; }
.ho-code {
  margin: 0;
  flex: 1;
  overflow: auto;
  white-space: pre;
  font: 13px/1.45 ui-monospace, Menlo, Consolas, monospace;
  color: #e8eaed;
}

/* ---- captions, status, controls ---- */
.ho-captions {
  min-height: 1.5em;
  padding: 10px 16px 0;
  text-align: center;
  font-size: 16px;
  line-height: 1.4;
}
.ho-cap { max-width: 720px; margin: 0 auto; }
.ho-cap:empty { display: none; }
.ho-cap-me { color: var(--ho-dim); font-size: 14px; }
.ho-status {
  min-height: 1.2em;
  text-align: center;
  font-size: 13px;
  color: var(--ho-dim);
  padding-top: 4px;
}
.ho-controls {
  display: flex;
  justify-content: center;
  gap: 16px;
  padding: 12px 16px 20px;
}
.ho-btn {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 0;
  background: var(--ho-tile);
  color: var(--ho-text);
  font-size: 18px;
  cursor: pointer;
}
.ho-btn:disabled { opacity: 0.5; cursor: default; }
.ho-btn.muted { background: var(--ho-red); }
.ho-hang { background: var(--ho-red); width: 64px; border-radius: 26px; }

/* ---- Harriet Humbug (HR) - drops in on the call ---- */
.ho-harriet {
  left: 12px;
  bottom: 12px;
  width: var(--ho-pip-w);
  aspect-ratio: 4 / 3;
  background: #5c4a63;
  z-index: 2;
  display: none;
}
.ho.harriet-here .ho-harriet { display: flex; animation: ho-join 0.5s ease-out; }
.ho-harriet .ho-face { width: auto; height: 62%; }
.ho.harriet-speaking .ho-harriet { box-shadow: 0 0 0 3px #f28b82; }
.ho.harriet-speaking .ho-harriet .ho-face { animation: ho-talk 0.4s ease-in-out infinite alternate; }
.ho.harriet-speaking .ho-harriet .ho-mic { color: #f28b82; }
.ho.harriet-speaking .ho-cap-ai { color: #f28b82; }
@keyframes ho-join { from { transform: scale(0.3); opacity: 0; } }
.ho-toast {
  position: absolute;
  left: 50%;
  top: 12px;
  transform: translateX(-50%);
  z-index: 3;
  padding: 8px 14px;
  border-radius: 8px;
  background: rgba(32, 33, 36, 0.92);
  font-size: 13px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
}
.ho-toast.show { animation: ho-toast 5s ease forwards; }
@keyframes ho-toast { 8%, 85% { opacity: 1; } 100% { opacity: 0; } }

/* her interjection in the chat transcript */
.message-harriet {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  max-width: 800px; /* match the normal .message column width */
  margin: 8px 0;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(242, 139, 130, 0.12);
  border-left: 3px solid #f28b82;
}
.harriet-avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; flex: none; }
.harriet-name { font-size: 12px; color: #f28b82; margin-bottom: 2px; }
.harriet-text { white-space: pre-wrap; }
.harriet-share { display: block; max-width: 220px; border-radius: 8px; margin-top: 6px; }
/* her tile sits bottom-left - move WhackGPT's name label out from under it */
.ho.harriet-here:not(.presenting) .ho-ai > .ho-name { top: 10px; bottom: auto; }

/* your turn: your tile pulses and the status says "speak now" */
.ho.my-turn .ho-me { animation: ho-your-turn 1.4s ease-in-out infinite; }
.ho.my-turn .ho-me .ho-mic { color: var(--ho-accent); }
.ho.my-turn .ho-status { color: var(--ho-accent); font-weight: 500; }
@keyframes ho-your-turn {
  0%, 100% { box-shadow: 0 0 0 2px rgba(138, 180, 248, 0.35); }
  50% { box-shadow: 0 0 0 4px var(--ho-accent), 0 0 18px 4px rgba(138, 180, 248, 0.55); }
}

/* The area under the stage keeps ONE fixed height in every state - captions
   and status text coming and going (thinking / speaking / your words) used
   to resize it, nudging the stage, which looked like the glow moved things. */
.ho-captions {
  height: 3.6em;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.ho-cap {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.ho-status {
  height: 1.4em;
  min-height: 0;
  line-height: 1.4em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Jacob the intern's bubble - same shape as Harriet's, sunnier */
.message-haruto { background: rgba(253, 214, 99, 0.12); border-left-color: #fdd663; }
.message-haruto .harriet-name { color: #fdd663; }

/* after the handoff Jacob stays on the call - a quiet tile, top-left */
.ho-haruto {
  left: 12px;
  top: 12px;
  width: var(--ho-pip-w);
  aspect-ratio: 4 / 3;
  background: #4f5a3a;
  z-index: 2;
  display: none;
}
.ho.haruto-quiet .ho-haruto { display: flex; animation: ho-join 0.5s ease-out; }
.ho-haruto .ho-face { width: auto; height: 62%; opacity: 0.85; }
.ho-haruto .ho-mic { color: var(--ho-red); }
.ho.haruto-speaking .ho-haruto { box-shadow: 0 0 0 3px #fdd663; }
.ho.haruto-speaking .ho-haruto .ho-face { animation: ho-talk 0.4s ease-in-out infinite alternate; }
.ho.haruto-speaking .ho-haruto .ho-mic { color: #fdd663; }
/* the "presenting" label sits top-left too - Jacob's tile covers it, so
   push the presenting area's label right of him */
.ho.haruto-quiet.presenting .ho-present-label { padding-left: calc(var(--ho-pip-w) + 24px); }
/* the join notice sits top-centre - move it below the top tiles */
.ho.haruto-quiet .ho-toast { top: calc(var(--ho-pip-w) * 0.75 + 24px); }
/* with Jacob top-left and/or Harriet bottom-left, Fernando's name label goes top-right */
.ho.haruto-quiet:not(.presenting) .ho-ai > .ho-name,
.ho.harriet-here:not(.presenting) .ho-ai > .ho-name { top: 10px; bottom: auto; left: auto; right: 12px; }

/* ---- create_document: a page in a little word processor ---- */
.wp-doc {
  display: flex;
  flex-direction: column;
  /* the chat column is a flex column: in a long chat its children shrink,
     and with overflow:hidden this one shrank to its borders */
  flex-shrink: 0;
  width: min(100%, 720px);
  margin: 8px 0;
  border: 1px solid #c8ccd2;
  border-radius: 8px;
  overflow: hidden;
  background: #e8eaed;
  color: #202124;
  font-family: system-ui, sans-serif;
}
.wp-titlebar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: #2b579a;
  color: #fff;
  font-size: 13px;
}
.wp-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wp-dl { background: none; border: 0; color: #fff; cursor: pointer; font-size: 13px; padding: 2px 4px; }
.wp-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 5px 10px;
  background: #f3f3f3;
  border-bottom: 1px solid #d0d0d0;
  color: #444;
  font-size: 12px;
  overflow: hidden;
  white-space: nowrap;
}
.wp-font, .wp-size { border: 1px solid #ccc; background: #fff; padding: 1px 6px; border-radius: 2px; }
.wp-sep { width: 1px; height: 14px; background: #ccc; }
.wp-desk { padding: 16px; overflow: auto; max-height: 520px; }
.wp-page {
  background: #fff;
  max-width: 8.5in;
  margin: 0 auto;
  padding: 48px 56px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
  font: 15px/1.55 "Times New Roman", Times, Georgia, serif;
  color: #111;
}
.wp-page h1, .wp-page h2, .wp-page h3 { font-family: Calibri, Carlito, "Segoe UI", sans-serif; color: #1f3864; margin: 0.8em 0 0.4em; }
.wp-page h1 { font-size: 24px; } .wp-page h2 { font-size: 19px; } .wp-page h3 { font-size: 16px; }
.wp-page p { margin: 0 0 0.8em; }
.wp-page table { border-collapse: collapse; margin: 0.6em 0; }
.wp-page th, .wp-page td { border: 1px solid #999; padding: 4px 8px; }
.wp-page a { color: #0563c1; }
.wp-page img { max-width: 100%; }
.wp-status { padding: 3px 10px; background: #2b579a; color: #dfe6f3; font-size: 11px; }
@media (max-width: 600px) {
  .wp-page { padding: 24px 20px; font-size: 14px; }
  .wp-desk { padding: 8px; }
}
/* on the call's shared screen the document fills the presenting area */
.ho-present-body:has(.wp-doc) { align-items: stretch; justify-content: center; padding: 0; }
.wp-doc.wp-on-call { width: 100%; max-width: none; margin: 0; border: 0; border-radius: 0; }
.wp-doc.wp-on-call .wp-desk { flex: 1; max-height: none; min-height: 0; }
/* keep the app's global text/table styling off the page */
.wp-page :is(p, li, td, th, blockquote, span, strong, em) { font-family: "Times New Roman", Times, Georgia, serif; color: #111; }
.wp-page table { box-shadow: none !important; border-radius: 0 !important; overflow: visible; background: #fff; }

/* the private huddle: Fernando and Carol are muted and dimmed, Jacob has the line */
.ho-fern {
  left: 12px;
  top: 12px;
  width: var(--ho-pip-w);
  aspect-ratio: 4 / 3;
  background: #5f6368;
  z-index: 2;
  display: none;
}
.ho-fern .ho-name { white-space: nowrap; }
.ho.huddle .ho-fern { display: flex; animation: ho-join 0.5s ease-out; }
.ho-fern .ho-face { width: auto; height: 62%; }
.ho.huddle .ho-fern .ho-face,
.ho.huddle .ho-harriet .ho-face { opacity: 0.4; filter: grayscale(0.7); }
.ho-fern .ho-mic { color: var(--ho-red); }
.ho.huddle .ho-harriet .ho-mic::before { content: "\f131"; color: var(--ho-red); }
.ho.huddle .ho-toast { top: calc(var(--ho-pip-w) * 0.75 + 24px); }
.ho.huddle:not(.presenting) .ho-ai > .ho-name { top: 10px; bottom: auto; left: auto; right: 12px; }

/* the forgotten browser tab Fernando's screen share opens on */
/* align-items:stretch (like .wp-doc) so the browser FILLS the presenting area's
   height; with align-items:center it collapsed to content height and the live
   iframe (height:100%) rendered tiny */
.ho-present-body:has(.ho-browser) { padding: 0; align-items: stretch; justify-content: center; }
.ho-browser { flex: 1 1 auto; width: 100%; display: flex; flex-direction: column; background: #dee1e6; min-width: 0; }
.ho-br-tabs { display: flex; align-items: flex-end; gap: 8px; padding: 6px 8px 0; color: #5f6368; font-size: 11px; }
.ho-br-tab {
  display: flex; align-items: center; gap: 8px; max-width: 70%;
  padding: 6px 10px; background: #fff; border-radius: 8px 8px 0 0; color: #202124;
}
.ho-br-tab span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ho-br-bar { display: flex; align-items: center; gap: 10px; padding: 5px 8px; background: #fff; color: #5f6368; font-size: 12px; }
.ho-br-url {
  flex: 1; min-width: 0; padding: 4px 10px; border-radius: 14px; background: #f1f3f4; color: #202124;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.ho-br-url .fa-lock { color: #5f6368; font-size: 10px; }
.ho-br-view { flex: none; overflow: hidden; background: #fff; position: relative; }
.ho-browser { justify-content: flex-start; background: #dee1e6; }
.ho-br-page { width: 1280px; height: 800px; transform-origin: 0 0; }
.ho-br-page img, .ho-br-page iframe { width: 1280px; height: 800px; border: 0; display: block; object-fit: cover; object-position: top left; }
/* open_website: a LIVE iframe fills the view (not a scaled 1280x800 shot) */
.ho-browser-live .ho-br-view { flex: 1 1 auto; display: flex; }
.ho-br-frame { flex: 1 1 auto; width: 100%; height: 100%; border: 0; background: #fff; }
/* a YouTube video: a proper 16:9 that fills the WIDTH and centres, instead of
   a landscape video floating small inside the tall screen-share frame */
.ho-browser-yt { flex: 0 1 auto; align-self: center; }
.ho-browser-yt .ho-br-view { flex: 0 0 auto; display: block; width: 100%; aspect-ratio: 16 / 9; max-height: 100%; background: #000; }
.ho-browser-yt .ho-br-view .yt-embed { width: 100%; height: 100%; }

/* ---- Daddy: pops into the call after Jacob's nudes, then leaves ---- */
/* left column, centred between Jacob (top-left) and Carol (bottom-left) */
.ho-daddy {
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: var(--ho-pip-w);
  aspect-ratio: 4 / 3;
  background: #3b2f2a;
  z-index: 2;
  display: none;
}
.ho.daddy-here .ho-daddy { display: flex; animation: ho-daddy-join 0.5s ease-out; }
@keyframes ho-daddy-join { from { transform: translateY(-50%) scale(0.3); opacity: 0; } }
.ho-daddy .ho-face { width: auto; height: 62%; }
.ho.daddy-speaking .ho-daddy { box-shadow: 0 0 0 3px #c58af9; }
.ho.daddy-speaking .ho-daddy .ho-face { animation: ho-talk 0.4s ease-in-out infinite alternate; }
.ho.daddy-speaking .ho-daddy .ho-mic { color: #c58af9; }
/* his bubble in the chat */
.message-daddy { background: rgba(197, 138, 249, 0.12); border-left-color: #c58af9; }
.message-daddy .harriet-name { color: #c58af9; }
