/* Hydra Scale: fundo do kraken, menu lateral de vidro com ocultar automático e cartões transparentes. */
html { background: #05060a; }
body { background: transparent !important; }
.hy-fundo { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; background: #05060a; }
.hy-fundo { --hy-tint: #2f5fc8; }
html[data-theme="foxpriv"] .hy-fundo { --hy-tint: #a8222f; }
.hy-fundo::before { content: ""; position: absolute; inset: -8%; background: linear-gradient(var(--hy-tint), var(--hy-tint)), url(/img/hydra-kraken.jpg) 58% 40% / cover no-repeat; background-blend-mode: color, normal; filter: brightness(.66) saturate(.74) contrast(1.06); animation: hy-kraken 42s ease-in-out infinite alternate; will-change: transform; }
.hy-fundo::after { content: ""; position: absolute; inset: 0; background:
  radial-gradient(90% 70% at 72% 22%, #05060a30 0, #05060a88 55%, #05060af0 100%),
  linear-gradient(180deg, #05060acc 0, #05060a66 38%, #05060af5 100%),
  radial-gradient(60% 50% at 18% 92%, color-mix(in srgb, var(--hy-tint) 10%, transparent), transparent 70%); animation: hy-respira 9s ease-in-out infinite alternate; }
@keyframes hy-kraken { 0% { transform: scale(1.04) translate3d(-1.2%, 0, 0); } 50% { transform: scale(1.12) translate3d(1%, -1.2%, 0); } 100% { transform: scale(1.18) translate3d(-.6%, .8%, 0); } }
@keyframes hy-respira { from { opacity: .94; } to { opacity: 1; } }
body:has(#tela:not([data-aba="semana"])) .hy-fundo::before { filter: brightness(.42) saturate(.68) contrast(1.04); }

/* Cartões em vidro */
.cartao, .hero-sem > *, .numeros > *, .dia, .hy-contas, .hy-metricas > div, .hy-detalhe, .hy-det-numeros > div, .conta-card, .bloco-comeco {
  background: rgba(255, 255, 255, .04) !important; border: 1px solid rgba(255, 255, 255, .1) !important;
  -webkit-backdrop-filter: blur(16px) saturate(1.35); backdrop-filter: blur(16px) saturate(1.35); box-shadow: 0 10px 34px rgba(0, 0, 0, .28), inset 0 1px 0 rgba(255, 255, 255, .06);
}
.hy-contas { background: rgba(255, 255, 255, .035) !important; }
.hero-sem > .numeros, .numeros { background: none !important; border: 0 !important; -webkit-backdrop-filter: none !important; backdrop-filter: none !important; box-shadow: none !important; border-radius: 0 !important; }
.hy-metricas { margin: 18px 0 0; }
.dia { background: rgba(255, 255, 255, .03) !important; }

/* Menu lateral de vidro: só os ícones; ao passar o mouse abre; ao tirar, volta a se ocultar. */
@media (min-width: 801px) {
  :root { --rail: 78px; --aberto: 280px; }
  body { --largura-menu: var(--rail); padding-left: calc(var(--rail) + 30px); }
  body.menu-fixo { --largura-menu: var(--aberto); padding-left: calc(var(--aberto) + 30px); }
  .topo { inset: 14px auto 14px 14px; height: auto; width: var(--rail); border: 1px solid rgba(255, 255, 255, .11); border-radius: 30px; background: linear-gradient(160deg, rgba(34, 34, 40, .62), rgba(12, 12, 16, .66)); -webkit-backdrop-filter: blur(28px) saturate(1.5); backdrop-filter: blur(28px) saturate(1.5); box-shadow: 0 24px 70px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 255, 255, .09); transition: width .32s cubic-bezier(.2, .8, .2, 1), box-shadow .3s; overflow: visible; }
  body.menu-fixo .topo, .topo:hover, .topo:focus-within { width: var(--aberto); }
  .topo:hover:not(:focus-within), body.menu-auto .topo:hover { box-shadow: 0 30px 90px rgba(0, 0, 0, .65), 0 0 0 1px rgba(255, 42, 61, .18), inset 0 1px 0 rgba(255, 255, 255, .1); }
  .topo .topo-in { padding: 16px 10px 12px; gap: 8px; border-radius: inherit; overflow: hidden; }
  .topo .marca { height: 54px; padding: 4px 10px; flex: none; }
  .topo .marca-logo { width: 38px; height: 38px; }
  .topo .marca-identidade, .topo .aba .t, .topo .nav-grupo .nav-chevron, .topo .sidebar-recolher span, .op-status > div, .op-status > em { opacity: 0; max-width: 0; overflow: hidden; white-space: nowrap; transition: opacity .2s, max-width .3s; }
  body.menu-fixo .topo .marca-identidade, body.menu-fixo .topo .aba .t, body.menu-fixo .nav-grupo .nav-chevron, body.menu-fixo .sidebar-recolher span, body.menu-fixo .op-status > div, body.menu-fixo .op-status > em,
  .topo:hover .marca-identidade, .topo:hover .aba .t, .topo:hover .nav-grupo .nav-chevron, .topo:hover .sidebar-recolher span, .topo:hover .op-status > div, .topo:hover .op-status > em,
  .topo:focus-within .marca-identidade, .topo:focus-within .aba .t, .topo:focus-within .nav-grupo .nav-chevron, .topo:focus-within .sidebar-recolher span, .topo:focus-within .op-status > div, .topo:focus-within .op-status > em { opacity: 1; max-width: 190px; transition-delay: .06s; }
  .topo .aba .cont { display: none; } body.menu-fixo .topo .aba .cont, .topo:hover .aba .cont { display: inline; }
  .topo .marca-nome { font-size: 19px; }
  .topo .abas { padding: 0 2px 10px; gap: 3px; }
  .nav-grupo { gap: 10px; padding: 16px 10px 6px; min-height: 32px; font: 600 9.5px var(--f-texto); letter-spacing: .14em; color: rgba(255, 255, 255, .42); }
  .nav-grupo::after { display: block !important; content: ""; order: 1; flex: 1; height: 1px; background: linear-gradient(90deg, rgba(255, 255, 255, .14), transparent); min-width: 14px; }
  .nav-grupo .nav-chevron { order: 2; margin-left: 0; }
  .topo .nav-grupo { overflow: hidden; white-space: nowrap; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .nav-grupo { font-size: 0; }
  .topo .aba { min-height: 46px; padding: 5px 9px; gap: 12px; border-radius: 16px; overflow: hidden; font-weight: 500; letter-spacing: -.01em; }
  .topo .aba svg { width: 36px; height: 36px; padding: 9px; box-sizing: border-box; border-radius: 12px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .06); opacity: 1; transition: background .2s, color .2s, border-color .2s; }
  .topo .aba:hover { background: rgba(255, 255, 255, .06); }
  .topo .aba:hover svg { background: rgba(255, 255, 255, .09); }
  .topo .aba[aria-selected=true] { background: linear-gradient(135deg, rgba(255, 255, 255, .1), rgba(255, 255, 255, .04)); border-color: rgba(255, 255, 255, .13); box-shadow: 0 6px 20px rgba(0, 0, 0, .3), inset 0 1px 0 rgba(255, 255, 255, .08); }
  .topo .aba[aria-selected=true] svg { color: #ff4d5e; background: rgba(255, 42, 61, .16); border-color: rgba(255, 42, 61, .4); }
  .topo .aba.grupo-fechado { display: flex; }
  body.menu-fixo .topo .aba.grupo-fechado { display: none; }
  .sidebar-recolher { margin: 2px 0; padding: 6px 9px; gap: 12px; border-radius: 14px; }
  .sidebar-recolher svg { width: 36px; height: 36px; padding: 10px; box-sizing: border-box; border-radius: 12px; background: rgba(255, 255, 255, .04); }
  .topo .topo-dir { padding: 10px 0 0; border-top: 1px solid rgba(255, 255, 255, .08); }
  .topo .conta-card { border-radius: 18px; padding: 8px; gap: 10px; background: rgba(255, 255, 255, .06) !important; }
}
/* Cartão de status da operação */
.op-status { display: flex; align-items: center; gap: 12px; flex: none; margin: 2px 0 4px; padding: 11px 12px; border-radius: 18px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .09); }
.op-status > i { width: 9px; height: 9px; border-radius: 50%; flex: none; margin: 0 5px; background: #37c978; box-shadow: 0 0 0 4px #37c97822; animation: hy-pulso 2.4s infinite; }
.op-status > div { display: grid; gap: 1px; min-width: 0; } .op-status b { font-size: 12.5px; font-weight: 650; } .op-status small { font-size: 10.5px; color: rgba(255, 255, 255, .55); }
.op-status > em { margin-left: auto; font-style: normal; font-size: 9.5px; font-weight: 700; padding: 3px 9px; border-radius: 99px; color: #37c978; background: #37c97820; border: 1px solid #37c97840; }
.op-status[data-estado="ruim"] > i { background: #ff2a3d; box-shadow: 0 0 0 4px #ff2a3d30; } .op-status[data-estado="ruim"] > em { color: #ff4d5e; background: #ff2a3d1f; border-color: #ff2a3d55; }
.op-status[data-estado="carregando"] > i { background: #e8a363; box-shadow: 0 0 0 4px #e8a36325; } .op-status[data-estado="carregando"] > em { color: #e8a363; background: #e8a3631f; border-color: #e8a36355; }
@media (max-width: 800px) {
  .op-status { display: none; }
  .topo .abas, .topo .topo-dir { background: rgba(14, 14, 18, .86) !important; -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px); border-color: rgba(255, 255, 255, .12); }
}
@media (prefers-reduced-motion: reduce) { .hy-fundo::before, .hy-fundo::after, .op-status > i { animation: none; } .topo { transition: none; } }
@media (min-width: 801px) { body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .op-status { padding: 11px 0; justify-content: center; gap: 0; } body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .op-status > i { margin: 0; } }

/* Menu recolhido: nada pode passar da largura da faixa */
.topo .abas { scrollbar-width: none; } .topo .abas::-webkit-scrollbar { display: none; }
@media (min-width: 801px) {
  .topo .aba, .topo .marca, .sidebar-recolher { gap: 0; }
  .topo .conta-card { gap: 12px; }
  .topo .aba { padding: 5px 11px; }
  .topo .aba .t, .topo .marca-identidade { margin-left: 0; }
  body.menu-fixo .topo .aba .t, .topo:hover .aba .t, .topo:focus-within .aba .t { margin-left: 12px; }
  body.menu-fixo .topo .marca-identidade, .topo:hover .marca-identidade, .topo:focus-within .marca-identidade { margin-left: 11px; }
  .sidebar-recolher { padding: 6px 11px; } .sidebar-recolher span { margin-left: 0; }
  body.menu-fixo .sidebar-recolher span, .topo:hover .sidebar-recolher span, .topo:focus-within .sidebar-recolher span { margin-left: 12px; }
  .topo .marca { padding: 4px 11px; }
  .op-status { box-sizing: border-box; width: 100%; min-width: 0; overflow: hidden; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .op-status { padding: 12px 0; justify-content: center; gap: 0; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .conta-card { justify-content: center; padding: 8px 0; }
  .topo .conta-card, .topo #contaAtiva { box-sizing: border-box; max-width: 100%; }
  .topo .nav-grupo { padding-left: 11px; padding-right: 11px; }
}
/* Lista do menu: sem caixa quadrada, sem setinhas de rolagem; as pontas esmaecem */
.topo .abas { background: transparent !important; border: 0 !important; border-radius: 22px !important; box-shadow: none !important; scrollbar-width: none !important; -ms-overflow-style: none;
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 16px, #000 calc(100% - 22px), transparent 100%); mask-image: linear-gradient(180deg, transparent 0, #000 16px, #000 calc(100% - 22px), transparent 100%); }
.topo .abas::-webkit-scrollbar, .topo .abas::-webkit-scrollbar-button, .topo .abas::-webkit-scrollbar-track { display: none !important; width: 0; height: 0; }
.topo .topo-in { border-radius: 30px; }

/* ===== Faixa recolhida: tudo centralizado numa coluna única de 58px ===== */
@media (min-width: 801px) {
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .topo-in { padding: 14px 10px 12px; align-items: stretch; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .marca { justify-content: center; padding: 4px 0; height: 52px; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .marca-identidade,
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .aba .t,
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .aba .cont,
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .sidebar-recolher span,
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .nav-grupo .nav-chevron,
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .op-status > div,
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .op-status > em { display: none !important; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .op-status { width: 46px; height: 46px; margin: 2px auto 6px; padding: 0; gap: 0; justify-content: center; align-items: center; border-radius: 16px; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .op-status > i { margin: 0; width: 10px; height: 10px; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .sidebar-recolher { justify-content: center; padding: 4px 0; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .abas { padding: 0 !important; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .aba { justify-content: center; padding: 5px 0; gap: 0; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .nav-grupo { justify-content: center; padding: 14px 0 6px; font-size: 0 !important; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .nav-grupo::after { flex: none; width: 26px; min-width: 0; background: rgba(255, 255, 255, .16); }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .topo-dir { align-items: center; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .conta-card { justify-content: center; padding: 8px 0; width: 100%; gap: 0; }
  body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .conta-resumo, body:not(.menu-fixo) .topo:not(:hover):not(:focus-within) .conta-seta { display: none !important; }
}

/* Cartão da conta: três linhas com respiro, sem uma colar na outra */
.topo .conta-card .conta-resumo { display: flex; flex-direction: column; justify-content: center; gap: 4px; min-width: 0; flex: 1; line-height: 1.3; }
.topo .conta-card .conta-resumo small, .topo .conta-card .conta-resumo b, .topo .conta-card .conta-resumo em { display: block; line-height: 1.3; margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topo .conta-card .conta-resumo small { font-size: 9px; letter-spacing: .1em; opacity: .65; }
.topo .conta-card .conta-resumo b { font-size: 13px; letter-spacing: -.01em; }
.topo .conta-card .conta-resumo em { font-size: 11px; opacity: .6; font-style: normal; }
.topo .conta-card .conta-seta { display: block; flex: none; width: 16px; height: 16px; }
.topo .conta-card { align-items: center; min-height: 64px; }

/* Celular e telas de toque: sem desfoque pesado nem animação contínua, para rodar liso e poupar bateria */
@media (max-width: 800px), (pointer: coarse) {
  .hy-fundo::before { animation: none; transform: scale(1.12); filter: brightness(.5) saturate(.7) contrast(1.04); }
  .hy-fundo::after { animation: none; }
  .cartao, .hero-sem > *, .numeros > *, .dia, .hy-contas, .hy-metricas > div, .hy-detalhe, .hy-det-numeros > div, .conta-card, .bloco-comeco { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(16, 16, 20, .74) !important; box-shadow: 0 6px 20px rgba(0, 0, 0, .3); }
  .topo { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(10, 10, 14, .94); }
  .logo-aura, .logo-t, .op-status > i { animation-iteration-count: 1; }
}
