body{
  --accent:var(--cyan);
}

/* Identidade Pandora: o simbolo permanece legivel em todos os temas. */
.pandora-brand-mark{
  position:relative;
  overflow:hidden;
  padding:0;
  border:none;
  border-radius:12px;
  background:transparent;
  box-shadow:none;
}

.pandora-brand-mark::before{
  content:'';
  position:absolute;
  top:50%;
  left:50%;
  width:22px;
  height:22px;
  border-radius:50%;
  background:radial-gradient(circle, rgba(253,211,110,.95) 0%, rgba(202,145,58,.5) 50%, rgba(202,145,58,0) 78%);
  filter:blur(2px);
  transform:translate(-50%,-50%) scale(.85);
  animation:pandora-brand-glow-pulse 3.2s ease-in-out infinite;
  pointer-events:none;
  z-index:0;
}

.pandora-brand-mark img{
  position:relative;
  z-index:1;
  display:block;
  width:100%;
  height:100%;
  object-fit:contain;
}

@keyframes pandora-brand-glow-pulse{
  0%,100%{opacity:.5; transform:translate(-50%,-50%) scale(.82);}
  50%{opacity:1; transform:translate(-50%,-50%) scale(1.12);}
}

.pandora-login-brand{
  justify-content:flex-start;
}

.pandora-login-lockup{
  display:block;
  width:min(330px,88vw);
  height:auto;
}

.pandora-chat-body{
  min-height:100dvh;
  overflow:hidden;
  display:block;
  padding:14px;
}

.pandora-chat-shell{
  position:relative;
  z-index:1;
  width:100%;
  height:calc(100dvh - 28px);
  max-width:980px;
  margin:0 auto;
}

.pandora-chat-app{
  height:100%;
  display:grid;
  grid-template-rows:auto 1fr auto auto;
  overflow:hidden;
}

.pandora-chat-header{
  min-height:74px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:14px 16px;
  border-bottom:1px solid rgba(255,255,255,.1);
  background:rgba(255,255,255,.035);
}

.pandora-agent{
  min-width:0;
  display:flex;
  align-items:center;
  gap:12px;
}

.pandora-agent-mark{
  width:42px;
  height:42px;
  flex:0 0 42px;
}

.pandora-agent h1{
  margin:0;
  font-family:'Space Grotesk',sans-serif;
  font-size:16px;
  letter-spacing:1px;
}

.pandora-agent p{
  display:flex;
  align-items:center;
  gap:6px;
  margin-top:4px;
  color:var(--text-muted);
  font-size:11px;
  line-height:1.25;
}

.pandora-status-dot{
  width:7px;
  height:7px;
  border-radius:50%;
  background:var(--emerald);
  box-shadow:0 0 14px var(--emerald-glow);
  flex:0 0 7px;
}

.pandora-header-actions{
  display:flex;
  align-items:center;
  gap:8px;
}

.pandora-status-dropdown{position:relative;}

/* Visibilidade agora e do OrionUI.Dropdown (.orion-dropdown/.is-open, ver
   assets/js/orion-ui/dropdown.js) - .orion-dropdown__menu ja parte de
   display:none por padrao. */
.pandora-status-popover{
  position:absolute;
  top:44px;
  right:0;
  left:auto;
  z-index:60;
  flex-direction:column;
  gap:4px;
  padding:8px;
  min-width:220px;
  max-width:min(300px, calc(100vw - 24px));
  background:linear-gradient(var(--panel-bg), var(--panel-bg)), var(--bg);
}
.orion-dropdown.is-open > .pandora-status-popover{display:flex;}

.pandora-status-row{
  display:flex;
  align-items:center;
  gap:10px;
  padding:8px 10px;
  border-radius:var(--r-sm);
  color:var(--text-main);
}

.pandora-status-row i{
  color:var(--primary);
  flex:0 0 auto;
  font-size:13px;
}

.pandora-status-popover-divider{
  height:1px;
  background:rgba(255,255,255,.08);
  margin:4px 2px;
}

.pandora-status-action{
  display:flex;
  align-items:center;
  gap:10px;
  padding:9px 10px;
  border-radius:var(--r-sm);
  border:0;
  background:transparent;
  color:var(--text-main);
  font-size:12px;
  font-weight:600;
  font-family:inherit;
  cursor:pointer;
  text-align:left;
  transition:.15s;
}

.pandora-status-action i{
  color:var(--primary);
  font-size:13px;
}

.pandora-status-action:hover{background:rgba(255,255,255,.06);}

.pandora-status-row span,
.pandora-status-row small{
  display:block;
  white-space:nowrap;
}

/* ===================== Faixa de aviso: notificacoes desativadas ===================== */
.pandora-notif-banner{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  gap:12px;
  padding:16px;
  margin-top:18px;
  border-radius:var(--r-sm);
  background:rgba(249,115,22,.10);
  border:1px solid rgba(249,115,22,.28);
}
.pandora-notif-banner.hidden{display:none;}
.pandora-notif-banner-text{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  font-size:13px;
  font-weight:600;
  color:var(--text-main);
}
.pandora-notif-banner-text i{color:var(--primary);font-size:15px;flex:0 0 auto;}
.pandora-notif-banner-actions{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  flex-wrap:wrap;
  flex:0 0 auto;
}
.pandora-notif-banner-activate,
.pandora-notif-banner-hide{
  flex:0 0 auto;
  height:32px;
  padding:0 14px;
  font-size:12px;
}

/* ===================== Modal de video (tutoriais, notificacoes) ===================== */
.pandora-video-modal-overlay{
  position:fixed;
  inset:0;
  z-index:10001;
  display:grid;
  place-items:center;
  padding:20px;
  background:rgba(0,0,0,.60);
  backdrop-filter:blur(10px);
  -webkit-backdrop-filter:blur(10px);
}
.pandora-video-modal-overlay.hidden{display:none;}
.pandora-video-modal-box{
  width:min(720px,100%);
  border-radius:var(--r-lg);
  background:rgba(14,14,24,.92);
  border:1px solid rgba(255,255,255,.18);
  box-shadow:0 24px 70px rgba(0,0,0,.58);
  overflow:hidden;
}
.pandora-video-modal-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:14px 16px;
}
.pandora-video-modal-header strong{font-size:14px;}
.pandora-video-modal-frame-wrap{
  position:relative;
  width:100%;
  padding-top:56.25%;
  background:#000;
}
.pandora-video-modal-frame-wrap iframe{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  border:0;
}

.pandora-install-manual-box{
  color:rgba(255,255,255,.92);
}
.pandora-install-manual-body{
  padding:4px 18px 20px;
  max-height:70vh;
  overflow-y:auto;
  display:flex;
  flex-direction:column;
  gap:16px;
}
.pandora-install-manual-section h4{
  display:flex;
  align-items:center;
  gap:8px;
  font-size:13px;
  margin:0 0 8px;
}
.pandora-install-manual-section ol{
  margin:0;
  padding-left:20px;
  font-size:13px;
  line-height:1.6;
  opacity:.85;
  display:flex;
  flex-direction:column;
  gap:4px;
}
.pandora-install-manual-section + .pandora-install-manual-section{
  padding-top:16px;
  border-top:1px solid rgba(255,255,255,.12);
}

/* ===================== Aviso de atualizacao disponivel (toast) =====================
   Nao usa overlay/blur de tela cheia -- e um card discreto ancorado no rodape,
   nao bloqueia o uso do app enquanto o usuario decide se quer atualizar agora. */
.pandora-update-toast{
  position:fixed;
  left:50%;
  bottom:16px;
  z-index:10001;
  width:min(380px,calc(100% - 24px));
  padding:16px 16px 18px;
  border-radius:var(--r-lg);
  background:rgba(20,20,30,.97);
  border:1px solid rgba(255,255,255,.14);
  box-shadow:0 20px 60px rgba(0,0,0,.5);
  color:rgba(255,255,255,.94);
  display:flex;
  flex-direction:column;
  gap:14px;
  transform:translate(-50%,calc(100% + 32px));
  opacity:0;
  pointer-events:none;
  transition:transform .38s cubic-bezier(.22,1,.36,1),opacity .3s ease;
}
.pandora-update-toast.visible{
  transform:translate(-50%,0);
  opacity:1;
  pointer-events:auto;
}
.pandora-update-toast-head{
  display:flex;
  align-items:flex-start;
  gap:12px;
}
.pandora-update-toast-icon{
  flex:0 0 auto;
  width:38px;
  height:38px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:linear-gradient(135deg,var(--primary),#c2410c);
  box-shadow:0 8px 20px var(--primary-glow);
  font-size:15px;
  color:#fff;
}
.pandora-update-toast-text{flex:1;min-width:0;}
.pandora-update-toast-text h4{
  font-size:14.5px;
  margin:0 0 3px;
}
.pandora-update-toast-text p{
  font-size:12.5px;
  opacity:.75;
  line-height:1.45;
  margin:0;
}
.pandora-update-toast-close{
  flex:0 0 auto;
  background:transparent;
  border:0;
  color:rgba(255,255,255,.5);
  cursor:pointer;
  font-size:13px;
  padding:4px;
  line-height:1;
  margin:-4px -4px 0 0;
}
.pandora-update-toast-close:hover{color:#fff;}
.pandora-update-toast-cta{
  width:100%;
  padding:13px;
  border:0;
  border-radius:calc(var(--r-lg) - 4px);
  background:linear-gradient(135deg,var(--primary),#c2410c);
  color:#fff;
  font-size:14.5px;
  font-weight:700;
  font-family:inherit;
  cursor:pointer;
  box-shadow:0 10px 26px var(--primary-glow);
  transition:.15s;
}
.pandora-update-toast-cta:hover{filter:brightness(1.08);transform:translateY(-1px);}
.pandora-update-toast-cta:active{transform:scale(.98);}

.pandora-status-row span{
  font-size:12px;
  font-weight:600;
}

.pandora-status-row small{
  margin-top:2px;
  color:var(--text-muted);
  font-size:10px;
}

.pandora-chat-messages{
  flex:1;
  min-height:0;
  overflow:auto;
  padding:18px;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.pandora-chat-messages .ai-msg{
  max-width:min(78%,720px);
  padding:11px 12px;
  border-radius:14px;
}

.pandora-chat-messages .ai-msg-user{
  border-bottom-right-radius:4px;
}

.pandora-chat-messages .ai-msg-assistant{
  border-bottom-left-radius:4px;
}

.pandora-chat-messages .ai-msg-text{
  font-size:13px;
  line-height:1.55;
}

.ai-msg-text.is-error{
  color:var(--rose);
}

.ai-msg-deeplink{
  margin-top:8px;
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:7px 12px;
  border:none;
  border-radius:999px;
  background:var(--primary);
  color:#fff;
  font-size:12px;
  font-weight:600;
  font-family:inherit;
  cursor:pointer;
}

.ai-msg-deeplink:hover{
  filter:brightness(1.08);
}

.pandora-chat-form{
  display:grid;
  grid-template-columns:1fr 48px;
  gap:10px;
  padding:12px 14px 14px;
  background:rgba(0,0,0,.12);
}

.pandora-chat-input{
  height:44px;
}

.pandora-send-btn{
  width:48px;
  min-width:0;
  height:44px;
  padding:0;
  justify-content:center;
}

@media (max-width:640px){
  .pandora-chat-body{
    padding:0;
  }

  .pandora-chat-shell{
    height:100dvh;
    max-width:none;
  }

  .pandora-chat-app{
    border-radius:0;
    border-left:0;
    border-right:0;
  }

  .pandora-chat-header{
    min-height:66px;
    padding:12px;
  }

  .pandora-agent-mark{
    width:38px;
    height:38px;
    flex-basis:38px;
  }

  .pandora-agent p{
    max-width:210px;
  }

  .pandora-status-popover{
    position:fixed;
    top:64px;
    left:12px;
    right:12px;
    min-width:0;
    max-width:none;
    width:auto;
  }

  .pandora-chat-messages{
    padding:14px 12px;
  }

  .pandora-chat-messages .ai-msg{
    max-width:90%;
  }

  .pandora-chat-form{
    padding:10px 12px 12px;
  }
}

.pandora-access-blocked-overlay{
  position:fixed;
  inset:0;
  z-index:5000;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:24px;
  background:rgba(5,5,10,.86);
  backdrop-filter:blur(6px);
}

.pandora-access-blocked-card{
  width:min(420px, 100%);
  max-height:90vh;
  overflow-y:auto;
  padding:32px 28px;
  text-align:center;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:14px;
}

.pandora-access-blocked-card i.fa-lock{
  font-size:32px;
  color:var(--primary);
}

.pandora-access-blocked-card h2{
  font-size:18px;
}

.pandora-access-blocked-card p{
  color:var(--text-muted);
  font-size:13px;
  line-height:1.5;
}

.pandora-checkout-form{
  width:100%;
  display:flex;
  flex-direction:column;
  gap:12px;
  text-align:left;
}

.pandora-checkout-form .field-group{
  display:flex;
  flex-direction:column;
  gap:6px;
}

.pandora-checkout-form .field-group label{
  font-size:11px;
  text-transform:uppercase;
  letter-spacing:1px;
  color:var(--text-muted);
  font-weight:700;
}

.pandora-checkout-loading{
  color:var(--text-muted);
  font-size:13px;
  text-align:center;
}

.pandora-checkout-total{
  font-weight:700;
  color:var(--primary);
  text-align:right;
}

/* Aviso de cobranca ja gerada e ainda nao paga, mostrado no lugar do formulario
   de checkout (criar outra assinatura seria recusado pelo backend). */
.pandora-checkout-pendente{
  font-size:13px;
  line-height:1.5;
  color:var(--text-muted);
  padding:10px 12px;
  border-radius:var(--r-sm);
  border:1px solid var(--panel-border);
  background:var(--panel-bg);
}
.pandora-checkout-pendente strong{color:var(--text-main);}

/* Os botoes desta tela sao <a> e <button> lado a lado; sem isso o link fica com
   altura de texto e desalinha da fileira. */
.pandora-checkout-form .orion-btn{justify-content:center;text-decoration:none;}

#checkoutResult{
  display:flex;
  flex-direction:column;
  gap:8px;
}
#checkoutResult a,
#checkoutResult button{
  width:100%;
  justify-content:center;
}

/* Icone SVG inline usado no lugar de um glifo do Font Awesome.
   Existe porque a familia "brands" do FA custava 118 KB de fonte para
   desenhar um unico icone (a maca do passo a passo de instalacao no iOS),
   entao ela nao e mais carregada — ver assets/vendor/fontawesome/README.md.
   O -.125em replica o alinhamento vertical que o proprio FA aplica nos
   glifos dele, para o SVG sentar na mesma linha de base do texto ao lado. */
.pandora-inline-icon{
  display:inline-block;
  vertical-align:-.125em;
}

/* Banner de consentimento de cookies (assets/js/cookie-consent.js).
   Estas regras viviam num template string dentro do proprio JS, que criava um
   <style> e o injetava no <head>. Desde que a auditoria SEC-001 (2026-07-23)
   tirou 'unsafe-inline' de style-src, o CSP bloqueava essa folha e o banner
   renderizava sem estilo NENHUM em todas as paginas. A auditoria migrou os
   style="" e os <style> que estavam no HTML, mas nao alcancou este, que so
   existe em tempo de execucao. Mantenha as regras aqui: qualquer CSS criado
   via JS volta a esbarrar no mesmo CSP. */
.pandora-cookie-banner{
  position:fixed;
  left:16px;
  right:16px;
  bottom:16px;
  z-index:9999;
  max-width:640px;
  margin:0 auto;
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:12px;
  padding:16px 20px;
  border-radius:14px;
  background:rgba(20,20,28,.96);
  color:#f2f2f5;
  border:1px solid rgba(255,255,255,.12);
  box-shadow:0 8px 30px rgba(0,0,0,.35);
  font-size:14px;
  line-height:1.5;
  font-family:inherit;
}
.pandora-cookie-banner p{margin:0;flex:1 1 260px;}
.pandora-cookie-banner a{color:inherit;text-decoration:underline;}
.pandora-cookie-banner button{
  flex:0 0 auto;
  border:none;
  border-radius:8px;
  padding:9px 18px;
  font-size:14px;
  font-weight:600;
  cursor:pointer;
  background:#f43f5e;
  color:#fff;
}
@media (prefers-color-scheme:light){
  .pandora-cookie-banner{
    background:rgba(255,255,255,.98);
    color:#1a1a1f;
    border-color:rgba(0,0,0,.1);
  }
}
