/* ==========================================================================
   Hyperframes — telas da Jornada ConnVC em HTML animado
   ========================================================================== */
.hf { --hf-bg: #0d1830; --hf-panel: #12203d; --hf-line: rgba(255,255,255,.08); --hf-txt: #dfe6f5; --hf-mut: #8d9bb8;
  border-radius: 18px; overflow: hidden; background: var(--hf-bg); color: var(--hf-txt); box-shadow: var(--shadow-lg), 0 0 0 1px rgba(255,255,255,.08);
  font: 400 12px/1.4 var(--font-body); text-align: left; position: relative; }
.hf-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; background: #0a1326; border-bottom: 1px solid var(--hf-line); }
.hf-bar i { width: 10px; height: 10px; border-radius: 50%; background: #ff6150; }
.hf-bar i:nth-child(2) { background: #ffc24a; }
.hf-bar i:nth-child(3) { background: #25d366; }
.hf-bar span { margin-left: 8px; font: 600 12px var(--font-head); color: var(--hf-mut); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hf-live { margin-left: auto; font: 700 10px var(--font-head); color: #25d366; text-transform: uppercase; letter-spacing: .1em; display: flex; align-items: center; gap: 6px; }
.hf-live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #25d366; animation: pulse 1.6s infinite; }
.hf-body { display: flex; min-height: 340px; }
.hf [data-t] { opacity: 0; transform: translateY(8px); transition: opacity .45s var(--ease), transform .45s var(--ease); }
.hf [data-t].on { opacity: 1; transform: none; }
.hf svg { width: 16px; height: 16px; }

.hf-side { width: 46px; flex: none; background: #0a1326; border-right: 1px solid var(--hf-line); display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 0; }
.hf-side span { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; color: var(--hf-mut); }
.hf-side span.act { background: var(--grad); color: #fff; }

.hf-list { width: 34%; flex: none; border-right: 1px solid var(--hf-line); padding: 10px; display: flex; flex-direction: column; gap: 6px; }
.hf-tabs { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 4px; }
.hf-tabs span { flex-shrink: 0; padding: 5px 8px; border-radius: 8px; font: 600 10.5px var(--font-head); color: var(--hf-mut); white-space: nowrap; }
.hf-tabs span.act { background: rgba(255,97,80,.16); color: #ff9a8e; }
.hf-tabs em { font-style: normal; background: #ff6150; color: #fff; border-radius: 99px; padding: 0 5px; margin-left: 2px; }
.hf-conv { display: flex; gap: 8px; align-items: flex-start; padding: 8px; border-radius: 10px; background: var(--hf-panel); position: relative; }
.hf-conv b { display: block; font: 600 11.5px var(--font-head); color: #fff; }
.hf-conv small { color: var(--hf-mut); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 150px; }
.hf .av { width: 30px; height: 30px; flex: none; border-radius: 50%; background: var(--c, #445); color: #fff; display: grid; place-items: center; font: 700 12px var(--font-head); position: relative; }
.hf .av em { position: absolute; right: -4px; bottom: -4px; width: 15px; height: 15px; border-radius: 50%; background: #0d1830; display: grid; place-items: center; color: var(--c); }
.hf .av em svg { width: 10px; height: 10px; }
.hf-tag { display: inline-block; margin-top: 4px; font: 600 9.5px var(--font-head); padding: 2px 6px; border-radius: 6px; background: rgba(255,138,31,.18); color: #ffb26b; }
.hf-badge { position: absolute; right: 8px; top: 8px; background: #25d366; color: #fff; border-radius: 99px; font: 700 10px var(--font-head); padding: 1px 6px; }

.hf-chat { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.hf-chat-top { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--hf-line); }
.hf-chat-top b { display: block; font: 600 12px var(--font-head); color: #fff; }
.hf-chat-top small { color: var(--hf-mut); }
.hf-pill { margin-left: auto; width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: rgba(255,255,255,.06); color: #fff; flex: none; }
.hf-pill + .hf-pill { margin-left: 6px; }
.hf-msgs { flex: 1; padding: 12px; display: flex; flex-direction: column; gap: 8px; background: radial-gradient(circle at 70% 0%, rgba(255,97,80,.06), transparent 60%); }
.hf-msgs p { margin: 0; max-width: 82%; padding: 8px 10px; border-radius: 12px; font-size: 12px; }
.hf-msgs .in { align-self: flex-start; background: var(--hf-panel); border-top-left-radius: 3px; }
.hf-msgs .out { align-self: flex-end; background: #1f5f4f; color: #eafff5; border-top-right-radius: 3px; }
.hf-msgs .out.ai { background: linear-gradient(135deg, #3a2a63, #2a2f6b); color: #f1edff; }
.ai-b { display: inline-block; font: 800 9px var(--font-head); background: var(--grad); color: #fff; border-radius: 5px; padding: 1px 5px; margin-right: 6px; vertical-align: 1px; }
.hf-msgs .note { align-self: center; max-width: 95%; background: rgba(255,194,74,.12); color: #ffd98a; font-size: 11px; display: flex; gap: 6px; align-items: center; }
.hf-msgs .note svg { width: 13px; height: 13px; flex: none; }

.hf-info { width: 24%; flex: none; border-left: 1px solid var(--hf-line); padding: 12px; display: flex; flex-direction: column; gap: 6px; }
.hf-info b { font: 700 10px var(--font-head); text-transform: uppercase; letter-spacing: .08em; color: var(--hf-mut); margin-top: 6px; }
.hf-chips { display: flex; gap: 4px; flex-wrap: wrap; }
.hf-chips span { font: 600 10px var(--font-head); padding: 3px 7px; border-radius: 6px; background: rgba(255,97,80,.16); color: #ff9a8e; }
.hf-opp { background: var(--hf-panel); border-radius: 10px; padding: 8px; border-left: 3px solid #ff8a1f; }
.hf-opp small, .hf-opp strong, .hf-opp em { display: block; }
.hf-opp strong { color: #fff; font: 700 14px var(--font-head); }
.hf-opp em { font-style: normal; color: var(--hf-mut); font-size: 10.5px; }

/* copiloto */
.hf-chat.solo .hf-msgs { min-height: 240px; padding: 18px; }
/* barra fixa embaixo: menu da IA + campo de digitar, com espaço reservado */
.hf-dock { display: flex; flex-direction: column; gap: 8px; padding: 10px 18px 18px; border-top: 1px solid var(--hf-line); }
.hf-compose { display: grid; background: #0a1326; border: 1px solid rgba(255,97,80,.4); border-radius: 12px; padding: 10px 12px; font-size: 12px; }
.hf-compose > *, .hf-draft > * { grid-area: 1 / 1; align-self: start; }
.hf-compose .ph { color: var(--hf-mut); opacity: .6; }
.hf-compose:has(.hf-draft.on) .ph { animation: hfPh 3.3s forwards; }
.hf-draft { display: grid; background: #0a1326; }
.hf .hf-draft.on { animation: hfOut .3s 2.9s forwards; }
.hf .hf-draft:not(.on), .hf .hf-menu:not(.on) { transition: none; }
.hf-compose .typed { overflow: hidden; white-space: nowrap; width: 0; max-width: 100%; border-right: 2px solid #ff6150; color: var(--hf-mut); justify-self: start; }
.hf-draft.on .typed { animation: hfType .9s steps(22) forwards, hfOut .3s 2.1s forwards; }
.hf-compose .better { opacity: 0; color: #fff; }
.hf-draft.on .better { animation: hfIn .5s 2.2s forwards; }
@keyframes hfPh { 0%, 95% { opacity: 0; } 100% { opacity: .6; } }
.hf-menu { align-self: flex-end; min-height: 25px; display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.hf-menu span { display: inline-flex; align-items: center; gap: 5px; font: 600 10.5px var(--font-head); background: var(--hf-panel); padding: 6px 9px; border-radius: 8px; color: var(--hf-txt); }
.hf-menu span.act { background: var(--grad); color: #fff; }
.hf .hf-menu.on { animation: hfOut .3s 1.2s forwards; }
.hf-menu svg { width: 13px; height: 13px; }

/* CRM */
.hf-crm, .hf-dash { flex: 1; padding: 12px; display: flex; flex-direction: column; gap: 10px; position: relative; min-width: 0; }
.hf-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.hf-kpis div { background: var(--hf-panel); border-radius: 10px; padding: 8px 10px; }
.hf-kpis small { display: block; color: var(--hf-mut); font-size: 10px; }
.hf-kpis b { font: 800 16px var(--font-head); color: #fff; white-space: nowrap; }
.hf-board { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; flex: 1; }
.hf-col { background: rgba(255,255,255,.03); border-radius: 10px; padding: 8px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.hf-col h6 { margin: 0 0 2px; font: 700 10px var(--font-head); color: var(--hf-txt); text-transform: uppercase; letter-spacing: .06em; display: flex; justify-content: space-between; align-items: center; }
.hf-col h6 em { font-style: normal; color: var(--hf-mut); }
.hf-col h6 svg { width: 13px; height: 13px; color: #ffc24a; }
.hf-col.win { background: rgba(37,211,102,.06); }
.hf-card { background: #fff; color: #0b1f3f; border-radius: 8px; padding: 7px 8px; border-left: 3px solid #ff6150; box-shadow: 0 6px 14px -8px rgba(0,0,0,.6); }
.hf-card b { display: block; font: 700 11px var(--font-head); }
.hf-card small { color: #5d6b85; font-size: 10px; }
.hf-card.won { border-left-color: #25d366; }
.hf .hf-card.mover { opacity: 1; transform: none; }
.hf .hf-card.mover.on { animation: hfLift 1.4s var(--ease) forwards; }
.hf .hf-card.ghost.on { animation: hfGhost 1.2s var(--ease) forwards; border-left-color: #ffc24a; }
.hf-toast { position: absolute; right: 14px; bottom: 14px; background: var(--grad); color: #fff; font: 700 11px var(--font-head); padding: 8px 12px; border-radius: 10px; display: flex; gap: 6px; align-items: center; box-shadow: 0 10px 24px -8px rgba(255,97,80,.7); }

/* Dashboard */
.hf-charts { display: grid; grid-template-columns: 1.4fr 1fr; gap: 10px; flex: 1; }
.hf-line, .hf-bars { background: var(--hf-panel); border-radius: 10px; padding: 10px; }
.hf-line small, .hf-bars small { color: var(--hf-mut); font-size: 10px; display: block; margin-bottom: 6px; }
.hf-line svg { width: 100%; height: 150px; }
.hf-line .ln { fill: none; stroke: #ff6150; stroke-width: 2.5; stroke-dasharray: 500; stroke-dashoffset: 500; }
.hf-line .area { fill: rgba(255,97,80,.14); opacity: 0; }
.hf.run .hf-line .ln { animation: hfDraw 2s var(--ease) forwards; }
.hf.run .hf-line .area { animation: hfIn 1s 1.2s forwards; }
.hf-bars div { display: grid; grid-template-columns: 62px 1fr; align-items: center; gap: 6px; margin: 9px 0; font-size: 10.5px; }
.hf-bars i { height: 9px; border-radius: 9px; background: var(--c); width: 0; transition: width 1.4s var(--ease); }
.hf.run .hf-bars i { width: var(--w); }

/* Videochamada */
.hf-video { display: flex; flex: 1; }
.hf-stage { flex: 1; padding: 12px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.hf-share { flex: 1; background: #fff; border-radius: 10px; padding: 12px; display: flex; flex-direction: column; justify-content: space-between; min-height: 150px; }
.hf-slide b { display: block; color: #0b1f3f; font: 800 14px var(--font-head); margin-bottom: 10px; }
.hf-slide i { display: block; height: 8px; border-radius: 8px; background: #e3e8f2; margin: 7px 0; }
.hf-slide i:nth-of-type(1) { width: 80%; background: linear-gradient(90deg, #ff6150, #ff8a1f); }
.hf-slide i:nth-of-type(2) { width: 60%; }
.hf-slide i:nth-of-type(3) { width: 70%; }
.hf-share small { color: #5d6b85; display: flex; gap: 5px; align-items: center; font-size: 10px; }
.hf-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.hf-tile { aspect-ratio: 16 / 10; border-radius: 10px; background: linear-gradient(160deg, #1d2f55, #0d1830); display: grid; place-items: center; position: relative; }
.hf-tile span { width: 32px; height: 32px; border-radius: 50%; background: var(--c); display: grid; place-items: center; font: 800 13px var(--font-head); color: #fff; }
.hf-tile small { position: absolute; left: 6px; bottom: 4px; font-size: 9.5px; color: #fff; }
.hf-tile.speak { box-shadow: 0 0 0 2px #25d366; animation: hfSpeak 1.2s infinite; }
.hf-ctrl { display: flex; gap: 6px; justify-content: center; align-items: center; flex-wrap: wrap; }
.hf-ctrl span { height: 28px; min-width: 28px; padding: 0 8px; border-radius: 99px; background: rgba(255,255,255,.08); display: grid; place-items: center; font: 700 10px var(--font-head); }
.hf-ctrl .rec { color: #ff6150; animation: blink 1.6s infinite; }
.hf-ctrl .end { background: #ec4b3a; color: #fff; }
.hf-trans { width: 36%; flex: none; border-left: 1px solid var(--hf-line); padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.hf-trans > b { font: 700 11px var(--font-head); color: #ff9a8e; display: flex; gap: 6px; align-items: center; }
.hf-trans p { margin: 0; font-size: 11px; color: var(--hf-txt); }
.hf-trans em { font-style: normal; color: var(--hf-mut); font-weight: 600; }
.hf-analysis { margin-top: auto; background: rgba(139,92,246,.16); border: 1px solid rgba(139,92,246,.4); border-radius: 10px; padding: 8px; display: flex; flex-direction: column; gap: 3px; }
.hf-analysis b { font: 700 11px var(--font-head); color: #fff; }
.hf-analysis small { color: #d9ccff; font-size: 10.5px; }

/* Chat interno */
.hf-call { align-self: center; display: flex; gap: 8px; align-items: center; background: #0a1326; border: 1px solid rgba(255,255,255,.12); border-radius: 12px; padding: 8px 12px; }
.hf .hf-call.on { animation: hfRing 1s infinite; }
.hf-call .ok, .hf-call .no { color: #fff; border-radius: 8px; padding: 4px 8px; font: 700 10px var(--font-head); }
.hf-call .ok { background: #25d366; }
.hf-call .no { background: #ec4b3a; }

.hf-stack { display: grid; gap: 18px; }
@media (min-width: 901px) { .page-hero-grid:has(.hf) { grid-template-columns: .85fr 1.15fr; gap: 40px; } .page-hero-grid:has(.hf) h1 { font-size: clamp(2rem, 3.6vw, 3.1rem); } }

/* Troque ferramentas */
.swap { display: grid; gap: 10px; max-width: 980px; margin-inline: auto; }
.swap-row { display: grid; grid-template-columns: 1fr 44px 1.2fr; align-items: center; gap: 10px; text-decoration: none !important; color: inherit; }
.swap-before { padding: 16px 18px; border-radius: 16px; border: 1.5px dashed #d5dbe7; color: var(--muted); text-decoration: line-through; text-decoration-color: rgba(255,97,80,.6); }
.swap-before small, .swap-after small { display: block; font: 700 .68rem var(--font-head); letter-spacing: .1em; text-transform: uppercase; text-decoration: none; color: var(--muted); margin-bottom: 2px; }
.swap-arrow { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--grad); color: #fff; transition: transform .3s var(--ease); }
.swap-arrow svg { width: 20px; height: 20px; }
.swap-after { display: flex; gap: 12px; align-items: center; padding: 14px 18px; border-radius: 16px; background: linear-gradient(160deg, var(--navy-700), var(--navy-900)); color: #fff; font-weight: 600; transition: box-shadow .3s; }
.swap-after small { color: var(--coral-300); }
.swap-after .ico { flex: 0 0 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: rgba(255,97,80,.18); color: var(--coral-300); }
.swap-after .ico svg { width: 20px; height: 20px; }
.swap-row:hover .swap-arrow { transform: translateX(4px); }
.swap-row:hover .swap-after { box-shadow: var(--glow); }
@media (max-width: 700px) { .swap-row { grid-template-columns: 1fr; } .swap-arrow { transform: rotate(90deg); margin: -4px auto; width: 34px; height: 34px; } .swap-row:hover .swap-arrow { transform: rotate(90deg); } }

/* Nota de análise (videochamadas) */
.note-card { background: #fff; color: var(--ink-2); border-radius: 22px; padding: 26px; box-shadow: var(--shadow-lg); border-left: 5px solid #8b5cf6; }
.note-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 14px; color: #8b5cf6; }
.note-head svg { width: 20px; height: 20px; }
.note-head b { font: 800 1.05rem var(--font-head); color: var(--ink); }
.note-head small { width: 100%; color: var(--muted); }
.note-card dl { margin: 0; display: grid; gap: 10px; }
.note-card dt { font: 700 .75rem var(--font-head); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.note-card dd { margin: 0; font-size: .95rem; color: var(--ink); }
.note-card .score { display: inline-block; background: var(--grad); color: #fff; font: 800 .85rem var(--font-head); padding: 2px 8px; border-radius: 8px; margin-right: 6px; }

/* Módulos (home) */
.modules { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 22px; }
.module { display: flex; gap: 12px; align-items: flex-start; padding: 18px; border-radius: 18px; background: #fff; border: 1px solid var(--line); color: inherit; text-decoration: none !important; transition: transform .3s var(--ease), box-shadow .3s; }
.module:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.module .ico { flex: 0 0 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--grad-soft); color: var(--coral-600); }
.module .ico svg { width: 22px; height: 22px; }
.module b { display: block; font: 700 .98rem var(--font-head); color: var(--ink); }
.module small { color: var(--muted); font-size: .84rem; line-height: 1.4; display: block; }
.module .new { display: inline-block; font: 800 .62rem var(--font-head); letter-spacing: .08em; background: var(--grad); color: #fff; border-radius: 6px; padding: 2px 6px; margin-left: 6px; vertical-align: 2px; }
@media (max-width: 980px) { .modules { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .modules { grid-template-columns: 1fr; } }
.event-band .txt .logo { align-self: flex-start; }

@keyframes hfType { to { width: 11.5em; } }
@keyframes hfIn { to { opacity: 1; } }
@keyframes hfOut { to { opacity: 0; } }
@keyframes hfDraw { to { stroke-dashoffset: 0; } }
@keyframes hfLift { 0% { transform: none; } 30% { transform: translateY(-4px) scale(1.04); box-shadow: 0 0 0 2px #ff6150, 0 14px 24px -8px rgba(255,97,80,.6); } 100% { transform: translateX(40%); opacity: 0; } }
@keyframes hfGhost { 0% { opacity: 0; transform: translateX(-30%); } 30% { opacity: 1; transform: none; } 75% { opacity: 1; } 100% { opacity: 0; transform: translateX(30%); } }
@keyframes hfSpeak { 50% { box-shadow: 0 0 0 4px rgba(37,211,102,.5); } }
@keyframes hfRing { 0%, 100% { transform: rotate(0); } 10% { transform: rotate(-2deg); } 20% { transform: rotate(2deg); } 30% { transform: rotate(0); } }

/* As telas se adaptam à largura do BLOCO onde estão (container queries), não à da janela:
   assim funcionam igual numa coluna estreita do desktop e no celular. */
.hf { container-type: inline-size; }
.hf-body, .hf-body * { min-width: 0; }
.hf-body { overflow-wrap: anywhere; }
.hf .av, .hf-pill, .hf-side, .hf-side span, .hf-badge, .ai-b { flex-shrink: 0; }
.hf-conv > div, .hf-chat-top > div { flex: 1; overflow: hidden; }
.hf-conv b, .hf-chat-top b, .hf-chat-top small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
.hf-conv small { max-width: none; }
@container (max-width: 760px) {
  .hf-side, .hf-info { display: none; }
  .hf-trans { width: 40%; }
}
@container (max-width: 620px) {
  .hf-body { font-size: 11px; }
  .hf-list { width: 42%; }
  .hf-trans { display: none; }
  .hf-kpis { grid-template-columns: 1fr 1fr; }
  .hf-board { grid-template-columns: 1fr 1fr; }
  .hf-board .hf-col:nth-child(1), .hf-board .hf-col:nth-child(3) { display: none; }
  .hf-charts { grid-template-columns: 1fr; }
  .hf-bar span { font-size: 11px; }
  .hf-msgs p { max-width: 92%; }
}
@container (max-width: 440px) {
  .hf-list { display: none; }
  .hf-live { display: none; }
  .hf-toast { left: 12px; right: 12px; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) { .hf [data-t] { transform: none; } }
