/* =========================================================
   IDEIAS HUB v1 — estilo (roxo com brilho, claro e escuro)
   ========================================================= */
:root {
  --roxo: #8b5cf6;
  --roxo-forte: #7c3aed;
  --roxo-escuro: #5b21b6;
  --rosa: #d946ef;
  --brilho: 0 0 0 1px rgba(139, 92, 246, .35), 0 8px 30px -6px rgba(139, 92, 246, .55);
  --raio: 14px;
  --raio-p: 10px;
  --verde: #22c55e;
  --amarelo: #f59e0b;
  --vermelho: #ef4444;
  --azul: #3b82f6;
  --fonte: 'Plus Jakarta Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}
:root, [data-tema="escuro"] {
  --fundo: #0d0819;
  --fundo-2: #130c24;
  --cartao: #181030;
  --cartao-2: #1f1640;
  --linha: rgba(167, 139, 250, .16);
  --linha-forte: rgba(167, 139, 250, .32);
  --texto: #f3f0ff;
  --texto-2: #b9b0d6;
  --texto-3: #8a80ab;
  --input: #120b26;
  --sombra: 0 10px 40px -12px rgba(0, 0, 0, .7);
  --gradiente-fundo: radial-gradient(1200px 600px at 85% -10%, rgba(124, 58, 237, .25), transparent 60%),
    radial-gradient(900px 500px at -10% 110%, rgba(217, 70, 239, .14), transparent 60%);
}
[data-tema="claro"] {
  --fundo: #f6f3ff;
  --fundo-2: #efe9ff;
  --cartao: #ffffff;
  --cartao-2: #f7f4ff;
  --linha: rgba(91, 33, 182, .12);
  --linha-forte: rgba(91, 33, 182, .26);
  --texto: #1d1236;
  --texto-2: #54497a;
  --texto-3: #8379a6;
  --input: #ffffff;
  --sombra: 0 10px 30px -14px rgba(76, 29, 149, .35);
  --gradiente-fundo: radial-gradient(1200px 600px at 85% -10%, rgba(139, 92, 246, .16), transparent 60%),
    radial-gradient(900px 500px at -10% 110%, rgba(217, 70, 239, .10), transparent 60%);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--fonte); background: var(--fundo); background-image: var(--gradiente-fundo);
  background-attachment: fixed; color: var(--texto); font-size: 14.5px; line-height: 1.5;
  -webkit-font-smoothing: antialiased; min-height: 100vh;
}
a { color: var(--roxo); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0; line-height: 1.25; letter-spacing: -.01em; }
h1 { font-size: 24px; font-weight: 800; }
h2 { font-size: 19px; font-weight: 700; }
h3 { font-size: 16px; font-weight: 700; }
p { margin: 0; }
small, .mudo { color: var(--texto-2); }
.mudo-3 { color: var(--texto-3); }
hr { border: 0; border-top: 1px solid var(--linha); margin: 18px 0; }
::selection { background: rgba(139, 92, 246, .35); }

/* ---------- carregando ---------- */
.tela-carregando { min-height: 100vh; display: grid; place-items: center; }
.logo-pulso { width: 56px; height: 56px; border-radius: 16px; background: linear-gradient(135deg, var(--roxo), var(--roxo-escuro)); box-shadow: var(--brilho); animation: pulso 1.2s ease-in-out infinite; }
@keyframes pulso { 50% { transform: scale(.88); opacity: .7; } }
.girando { width: 18px; height: 18px; border: 2px solid rgba(255,255,255,.35); border-top-color: #fff; border-radius: 50%; animation: gira .7s linear infinite; display: inline-block; vertical-align: middle; }
@keyframes gira { to { transform: rotate(360deg); } }

/* ---------- marca ---------- */
.logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; letter-spacing: -.02em; }
.logo-icone { width: 34px; height: 34px; border-radius: 10px; background: linear-gradient(135deg, #a855f7, var(--roxo-escuro)); display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 15px; box-shadow: var(--brilho); flex: none; }
.logo b { background: linear-gradient(90deg, #c4b5fd, var(--rosa)); -webkit-background-clip: text; background-clip: text; color: transparent; }
[data-tema="claro"] .logo b { background: linear-gradient(90deg, var(--roxo-forte), var(--rosa)); -webkit-background-clip: text; background-clip: text; }

/* ---------- botões ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: var(--raio-p); border: 1px solid var(--linha-forte); background: var(--cartao-2); color: var(--texto); font: 600 14px var(--fonte); cursor: pointer; transition: .15s; white-space: nowrap; text-decoration: none !important; }
.btn:hover { border-color: var(--roxo); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-p { height: 32px; padding: 0 11px; font-size: 13px; border-radius: 8px; }
.btn-primario { background: linear-gradient(135deg, #9b6bff, var(--roxo-forte)); border-color: transparent; color: #fff; box-shadow: var(--brilho); }
.btn-primario:hover { filter: brightness(1.08); border-color: transparent; }
.btn-perigo { color: #fca5a5; border-color: rgba(239, 68, 68, .4); background: rgba(239, 68, 68, .08); }
[data-tema="claro"] .btn-perigo { color: #b91c1c; }
.btn-perigo:hover { border-color: var(--vermelho); }
.btn-fantasma { background: transparent; border-color: transparent; color: var(--texto-2); }
.btn-fantasma:hover { background: var(--cartao-2); color: var(--texto); border-color: var(--linha); }
.btn-icone { width: 40px; padding: 0; }
.btn-bloco { width: 100%; }
.btn-verde { background: rgba(34, 197, 94, .12); border-color: rgba(34, 197, 94, .45); color: #86efac; }
[data-tema="claro"] .btn-verde { color: #15803d; }

/* ---------- formulários ---------- */
.campo { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.campo label, .rotulo { font-size: 12.5px; font-weight: 600; color: var(--texto-2); }
.campo .dica { font-size: 12px; color: var(--texto-3); }
input, select, textarea { font: 500 14px var(--fonte); color: var(--texto); background: var(--input); border: 1px solid var(--linha-forte); border-radius: var(--raio-p); padding: 10px 12px; outline: none; width: 100%; transition: .15s; }
input:focus, select:focus, textarea:focus { border-color: var(--roxo); box-shadow: 0 0 0 3px rgba(139, 92, 246, .2); }
textarea { resize: vertical; min-height: 90px; line-height: 1.5; }
input[type=checkbox], input[type=radio] { width: auto; accent-color: var(--roxo); }
input[type=color] { padding: 2px; height: 40px; }
.grade-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.grade-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 14px; }
.linha { display: flex; align-items: center; gap: 10px; }
.linha-entre { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.quebra { flex-wrap: wrap; }
.cresce { flex: 1; min-width: 0; }
.check { display: flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 500; }

/* ---------- autenticação ---------- */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.auth-lado { padding: 48px; display: flex; flex-direction: column; justify-content: space-between; background: linear-gradient(160deg, rgba(124, 58, 237, .35), rgba(13, 8, 25, .2) 60%), var(--fundo-2); border-right: 1px solid var(--linha); position: relative; overflow: hidden; }
.auth-lado::after { content: ""; position: absolute; width: 520px; height: 520px; border-radius: 50%; right: -180px; bottom: -200px; background: radial-gradient(circle, rgba(217, 70, 239, .35), transparent 65%); filter: blur(10px); }
.auth-lado h1 { font-size: 40px; line-height: 1.1; margin: 0 0 14px; max-width: 520px; }
.auth-lado h1 span { background: linear-gradient(90deg, #c4b5fd, var(--rosa)); -webkit-background-clip: text; background-clip: text; color: transparent; }
[data-tema="claro"] .auth-lado h1 span { background: linear-gradient(90deg, var(--roxo-forte), var(--rosa)); -webkit-background-clip: text; background-clip: text; }
.auth-lado .redes-linha { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 22px; position: relative; z-index: 1; }
.auth-form { display: grid; place-items: center; padding: 32px 20px; }
.auth-caixa { width: 100%; max-width: 400px; }
.auth-caixa h2 { font-size: 24px; margin-bottom: 6px; }
.auth-troca { margin-top: 18px; text-align: center; color: var(--texto-2); }
.auth-troca a { font-weight: 700; cursor: pointer; }

.planos-escolha { display: grid; gap: 10px; margin-bottom: 14px; }
.plano-op { display: flex; gap: 10px; align-items: flex-start; padding: 12px; border-radius: var(--raio-p); border: 1px solid var(--linha-forte); background: var(--cartao); cursor: pointer; transition: .15s; }
.plano-op:hover { border-color: var(--roxo); }
.plano-op.ativo { border-color: var(--roxo); box-shadow: var(--brilho); }
.plano-op .preco { margin-left: auto; font-weight: 800; white-space: nowrap; }

/* ---------- estrutura do app ---------- */
.app { display: grid; grid-template-columns: 252px 1fr; min-height: 100vh; }
.lateral { position: sticky; top: 0; height: 100vh; padding: 18px 14px; display: flex; flex-direction: column; gap: 6px; background: var(--fundo-2); border-right: 1px solid var(--linha); overflow-y: auto; z-index: 40; }
.lateral .logo { padding: 4px 8px 16px; }
.menu-titulo { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--texto-3); padding: 14px 10px 6px; }
.menu-item { display: flex; align-items: center; gap: 11px; padding: 9px 11px; border-radius: 10px; color: var(--texto-2); font-weight: 600; cursor: pointer; transition: .12s; text-decoration: none !important; border: 1px solid transparent; }
.menu-item:hover { background: var(--cartao); color: var(--texto); }
.menu-item.ativo { background: linear-gradient(135deg, rgba(139, 92, 246, .22), rgba(139, 92, 246, .08)); color: var(--texto); border-color: rgba(139, 92, 246, .35); box-shadow: 0 0 22px -8px rgba(139, 92, 246, .7); }
.menu-item svg { width: 18px; height: 18px; flex: none; }
.menu-item .selo { margin-left: auto; }
.lateral-pe { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--linha); }
.espaco-caixa { padding: 10px; border-radius: 12px; background: var(--cartao); border: 1px solid var(--linha); }
.espaco-caixa .nome { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.principal { min-width: 0; display: flex; flex-direction: column; }
.topo { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 12px; padding: 14px 28px; background: color-mix(in srgb, var(--fundo) 82%, transparent); backdrop-filter: blur(14px); border-bottom: 1px solid var(--linha); }
.topo h1 { font-size: 20px; }
.topo .acoes { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.btn-menu { display: none; }
.conteudo { padding: 26px 28px 60px; max-width: 1400px; width: 100%; }
.aviso-faixa { margin: 0 28px; margin-top: 16px; padding: 12px 16px; border-radius: 12px; border: 1px solid rgba(245, 158, 11, .45); background: rgba(245, 158, 11, .1); display: flex; gap: 12px; align-items: center; }

/* ---------- cartões ---------- */
.cartao { background: var(--cartao); border: 1px solid var(--linha); border-radius: var(--raio); padding: 18px; box-shadow: var(--sombra); }
.cartao-cab { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.grade-cartoes { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin-bottom: 20px; }
.kpi { background: var(--cartao); border: 1px solid var(--linha); border-radius: var(--raio); padding: 16px 18px; position: relative; overflow: hidden; }
.kpi::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 2px; background: linear-gradient(90deg, var(--roxo), var(--rosa)); opacity: .8; }
.kpi .rot { font-size: 12.5px; color: var(--texto-2); font-weight: 600; }
.kpi .val { font-size: 28px; font-weight: 800; letter-spacing: -.02em; margin-top: 4px; }
.kpi .sub { font-size: 12px; color: var(--texto-3); }
.duas-col { display: grid; grid-template-columns: 1.4fr 1fr; gap: 18px; }
.vazio { text-align: center; padding: 34px 16px; color: var(--texto-2); }
.vazio .ic { width: 52px; height: 52px; border-radius: 16px; margin: 0 auto 12px; display: grid; place-items: center; background: rgba(139, 92, 246, .14); color: var(--roxo); }
.vazio .ic svg { width: 24px; height: 24px; }
.vazio h3 { color: var(--texto); margin-bottom: 4px; }

/* ---------- selos ---------- */
.selo { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 700; border: 1px solid transparent; white-space: nowrap; }
.selo::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.selo.sem-ponto::before { display: none; }
.s-cinza { color: var(--texto-2); background: rgba(148, 163, 184, .12); border-color: rgba(148, 163, 184, .25); }
.s-roxo { color: #c4b5fd; background: rgba(139, 92, 246, .15); border-color: rgba(139, 92, 246, .35); }
.s-verde { color: #86efac; background: rgba(34, 197, 94, .12); border-color: rgba(34, 197, 94, .35); }
.s-amarelo { color: #fcd34d; background: rgba(245, 158, 11, .12); border-color: rgba(245, 158, 11, .35); }
.s-vermelho { color: #fca5a5; background: rgba(239, 68, 68, .12); border-color: rgba(239, 68, 68, .35); }
.s-azul { color: #93c5fd; background: rgba(59, 130, 246, .12); border-color: rgba(59, 130, 246, .35); }
[data-tema="claro"] .s-roxo { color: #6d28d9; }
[data-tema="claro"] .s-verde { color: #15803d; }
[data-tema="claro"] .s-amarelo { color: #b45309; }
[data-tema="claro"] .s-vermelho { color: #b91c1c; }
[data-tema="claro"] .s-azul { color: #1d4ed8; }

/* ---------- ícones de rede ---------- */
.rede-ic { width: 22px; height: 22px; border-radius: 7px; display: inline-grid; place-items: center; color: #fff; flex: none; }
.rede-ic svg { width: 13px; height: 13px; }
.rede-ic.g { width: 34px; height: 34px; border-radius: 10px; }
.rede-ic.g svg { width: 18px; height: 18px; }
.r-facebook { background: #1877f2; }
.r-instagram { background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fd5949 45%, #d6249f 60%, #285aeb 90%); }
.r-linkedin { background: #0a66c2; }
.r-google_negocio { background: #fff; color: #4285f4; border: 1px solid #dadce0; }
.r-youtube { background: #ff0000; }
.r-tiktok { background: #000; box-shadow: inset 0 0 0 1px rgba(255,255,255,.18); }
.r-pinterest { background: #e60023; }
.r-meta { background: linear-gradient(135deg, #0668e1, #0080fb); }

/* ---------- tabelas ---------- */
.tabela-caixa { overflow-x: auto; border-radius: var(--raio); border: 1px solid var(--linha); background: var(--cartao); }
table { width: 100%; border-collapse: collapse; }
th { text-align: left; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--texto-3); padding: 12px 14px; border-bottom: 1px solid var(--linha); background: var(--cartao-2); white-space: nowrap; }
td { padding: 12px 14px; border-bottom: 1px solid var(--linha); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: rgba(139, 92, 246, .05); }
.td-acoes { text-align: right; white-space: nowrap; }

/* ---------- abas ---------- */
.abas { display: flex; gap: 4px; padding: 4px; border-radius: 12px; background: var(--cartao); border: 1px solid var(--linha); margin-bottom: 20px; overflow-x: auto; }
.aba { padding: 8px 14px; border-radius: 9px; font-weight: 600; color: var(--texto-2); cursor: pointer; white-space: nowrap; border: 0; background: none; font-family: var(--fonte); font-size: 14px; }
.aba:hover { color: var(--texto); }
.aba.ativa { background: linear-gradient(135deg, #9b6bff, var(--roxo-forte)); color: #fff; box-shadow: var(--brilho); }

/* ---------- marcas ---------- */
.marca-cartao { cursor: pointer; transition: .15s; }
.marca-cartao:hover { border-color: var(--roxo); transform: translateY(-2px); }
.avatar { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-weight: 800; color: #fff; flex: none; overflow: hidden; background-size: cover; background-position: center; }
.avatar.p { width: 30px; height: 30px; border-radius: 9px; font-size: 12px; }
.avatar.g { width: 64px; height: 64px; border-radius: 18px; font-size: 22px; }
.mini-redes { display: flex; gap: 5px; flex-wrap: wrap; }

.redes-grade { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.rede-cartao { background: var(--cartao); border: 1px solid var(--linha); border-radius: var(--raio); padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.conta-linha { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; background: var(--cartao-2); border: 1px solid var(--linha); }
.conta-foto { width: 30px; height: 30px; border-radius: 50%; background: var(--cartao); background-size: cover; background-position: center; flex: none; display: grid; place-items: center; font-size: 12px; font-weight: 700; }

/* ---------- calendário ---------- */
.cal-cab { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.cal-cab h2 { min-width: 190px; }
.cal { display: grid; grid-template-columns: repeat(7, 1fr); border: 1px solid var(--linha); border-radius: var(--raio); overflow: hidden; background: var(--cartao); }
.cal-dsem { padding: 10px; font-size: 12px; font-weight: 700; color: var(--texto-3); text-transform: uppercase; letter-spacing: .05em; border-bottom: 1px solid var(--linha); background: var(--cartao-2); }
.cal-dia { min-height: 118px; padding: 8px; border-right: 1px solid var(--linha); border-bottom: 1px solid var(--linha); display: flex; flex-direction: column; gap: 4px; cursor: pointer; transition: background .12s; min-width: 0; }
.cal-dia:nth-child(7n) { border-right: 0; }
.cal-dia:hover { background: rgba(139, 92, 246, .06); }
.cal-dia.fora { opacity: .4; }
.cal-dia .num { font-size: 12.5px; font-weight: 700; color: var(--texto-2); width: 26px; height: 26px; display: grid; place-items: center; border-radius: 8px; }
.cal-dia.hoje .num { background: linear-gradient(135deg, #9b6bff, var(--roxo-forte)); color: #fff; box-shadow: var(--brilho); }
.cal-post { display: flex; align-items: center; gap: 5px; padding: 3px 6px; border-radius: 7px; font-size: 11.5px; font-weight: 600; background: var(--cartao-2); border-left: 3px solid var(--roxo); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: pointer; }
.cal-post:hover { filter: brightness(1.15); }
.cal-post .h { color: var(--texto-3); font-weight: 700; }
.cal-mais { font-size: 11.5px; color: var(--texto-3); font-weight: 600; padding-left: 4px; }

/* ---------- posts ---------- */
.post-linha { display: flex; gap: 14px; align-items: center; padding: 12px; border-radius: 12px; border: 1px solid var(--linha); background: var(--cartao); cursor: pointer; transition: .12s; }
.post-linha:hover { border-color: var(--roxo); }
.post-miniatura { width: 56px; height: 56px; border-radius: 10px; background: var(--cartao-2); background-size: cover; background-position: center; flex: none; display: grid; place-items: center; color: var(--texto-3); overflow: hidden; }
.post-miniatura video { width: 100%; height: 100%; object-fit: cover; }
.post-texto { min-width: 0; flex: 1; }
.post-texto .leg { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
.lista { display: flex; flex-direction: column; gap: 10px; }
.filtros { display: flex; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.filtros select, .filtros input { width: auto; min-width: 170px; height: 40px; padding: 0 12px; }

/* editor */
.editor { display: grid; grid-template-columns: 1fr 360px; gap: 22px; }
.destinos { display: flex; flex-wrap: wrap; gap: 8px; }
.destino-op { display: flex; align-items: center; gap: 8px; padding: 7px 11px 7px 8px; border-radius: 999px; border: 1px solid var(--linha-forte); background: var(--cartao-2); cursor: pointer; font-weight: 600; font-size: 13px; transition: .12s; user-select: none; }
.destino-op.marcado { border-color: var(--roxo); background: rgba(139, 92, 246, .16); box-shadow: 0 0 18px -6px rgba(139, 92, 246, .8); }
.destino-op input { display: none; }
.formatos { display: flex; gap: 6px; flex-wrap: wrap; }
.formato-op { padding: 7px 13px; border-radius: 9px; border: 1px solid var(--linha-forte); cursor: pointer; font-weight: 600; font-size: 13px; background: var(--cartao-2); }
.formato-op.marcado { border-color: var(--roxo); background: rgba(139, 92, 246, .18); color: var(--texto); }
.soltar { border: 2px dashed var(--linha-forte); border-radius: var(--raio); padding: 22px; text-align: center; cursor: pointer; transition: .15s; background: var(--cartao-2); }
.soltar:hover, .soltar.sobre { border-color: var(--roxo); background: rgba(139, 92, 246, .08); }
.midias { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 8px; margin-top: 10px; }
.midia { position: relative; aspect-ratio: 1; border-radius: 10px; overflow: hidden; background: var(--cartao-2); border: 1px solid var(--linha); }
.midia img, .midia video { width: 100%; height: 100%; object-fit: cover; display: block; }
.midia .tirar { position: absolute; top: 4px; right: 4px; width: 24px; height: 24px; border-radius: 50%; border: 0; background: rgba(0,0,0,.7); color: #fff; cursor: pointer; font-size: 14px; line-height: 1; }
.midia .ordem { position: absolute; left: 4px; bottom: 4px; background: rgba(0,0,0,.65); color: #fff; font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 6px; }
.midia .enviando { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0,0,0,.55); }
.contador { font-size: 12px; color: var(--texto-3); text-align: right; }
.contador.estourou { color: var(--vermelho); font-weight: 700; }

.previa { position: sticky; top: 90px; }
.previa-tel { border-radius: 26px; border: 1px solid var(--linha-forte); background: var(--fundo-2); padding: 14px; box-shadow: var(--sombra); }
.previa-post { background: var(--cartao); border-radius: 16px; overflow: hidden; border: 1px solid var(--linha); }
.previa-cab { display: flex; align-items: center; gap: 9px; padding: 10px 12px; }
.previa-img { aspect-ratio: 1; background: var(--cartao-2); display: grid; place-items: center; color: var(--texto-3); background-size: cover; background-position: center; position: relative; }
.previa-img video { width: 100%; height: 100%; object-fit: cover; }
.previa-img .qtd { position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,.65); color: #fff; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; }
.previa-leg { padding: 10px 12px 14px; font-size: 13px; white-space: pre-wrap; word-break: break-word; max-height: 220px; overflow: auto; }
.destino-status { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 10px; background: var(--cartao-2); border: 1px solid var(--linha); }

/* ---------- planos (admin e cadastro) ---------- */
.plano-cartao { position: relative; display: flex; flex-direction: column; gap: 10px; }
.plano-cartao.destaque { border-color: var(--roxo); box-shadow: var(--brilho); }
.plano-cartao .preco-g { font-size: 30px; font-weight: 800; letter-spacing: -.02em; }
.plano-cartao ul { margin: 0; padding-left: 18px; color: var(--texto-2); }
.plano-cartao.inativo { opacity: .55; }

/* ---------- espera ---------- */
.espera { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.espera .cartao { max-width: 560px; width: 100%; padding: 30px; }
.pix { font-family: ui-monospace, Menlo, monospace; padding: 12px; border-radius: 10px; background: var(--cartao-2); border: 1px dashed var(--linha-forte); word-break: break-all; }

/* ---------- modal ---------- */
.modal-fundo { position: fixed; inset: 0; z-index: 100; background: rgba(6, 3, 14, .66); backdrop-filter: blur(4px); display: grid; place-items: center; padding: 20px; animation: aparece .15s ease; overflow-y: auto; }
.modal { width: 100%; max-width: 560px; background: var(--cartao); border: 1px solid var(--linha-forte); border-radius: 18px; box-shadow: 0 30px 80px -20px rgba(0,0,0,.7), var(--brilho); animation: sobe .18s ease; max-height: calc(100vh - 40px); display: flex; flex-direction: column; }
.modal.largo { max-width: 1080px; }
.modal.medio { max-width: 760px; }
.modal-cab { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--linha); gap: 12px; }
.modal-corpo { padding: 20px 22px; overflow-y: auto; }
.modal-pe { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px; border-top: 1px solid var(--linha); flex-wrap: wrap; }
@keyframes aparece { from { opacity: 0; } }
@keyframes sobe { from { transform: translateY(12px); opacity: 0; } }

/* ---------- toasts ---------- */
#toasts { position: fixed; right: 20px; bottom: 20px; z-index: 200; display: flex; flex-direction: column; gap: 8px; }
.toast { min-width: 260px; max-width: 380px; padding: 12px 16px; border-radius: 12px; background: var(--cartao); border: 1px solid var(--linha-forte); box-shadow: var(--sombra); font-weight: 600; animation: sobe .2s ease; display: flex; gap: 10px; align-items: flex-start; }
.toast.ok { border-color: rgba(34, 197, 94, .5); }
.toast.erro { border-color: rgba(239, 68, 68, .55); }
.toast .bolinha { width: 8px; height: 8px; border-radius: 50%; margin-top: 7px; flex: none; background: var(--roxo); }
.toast.ok .bolinha { background: var(--verde); }
.toast.erro .bolinha { background: var(--vermelho); }

/* ---------- utilidades ---------- */
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 6px; } .mt-2 { margin-top: 12px; } .mt-3 { margin-top: 20px; } .mt-4 { margin-top: 28px; }
.mb-2 { margin-bottom: 12px; } .mb-3 { margin-bottom: 20px; }
.negrito { font-weight: 700; }
.pequeno { font-size: 12.5px; }
.centro { text-align: center; }
.oculto { display: none !important; }
.corta { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.caixa-info { padding: 12px 14px; border-radius: 12px; background: rgba(139, 92, 246, .1); border: 1px solid rgba(139, 92, 246, .3); color: var(--texto-2); font-size: 13.5px; }
.caixa-info b { color: var(--texto); }
.codigo { font-family: ui-monospace, Menlo, monospace; font-size: 12.5px; padding: 8px 10px; border-radius: 8px; background: var(--cartao-2); border: 1px solid var(--linha); word-break: break-all; }
.passos { margin: 8px 0 0; padding-left: 20px; color: var(--texto-2); font-size: 13.5px; }
.passos li { margin-bottom: 4px; }

/* ---------- responsivo ---------- */
@media (max-width: 1100px) {
  .editor { grid-template-columns: 1fr; }
  .previa { position: static; }
  .duas-col { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .auth { grid-template-columns: 1fr; }
  .auth-lado { display: none; }
  .app { grid-template-columns: 1fr; }
  .lateral { position: fixed; left: 0; top: 0; bottom: 0; width: 272px; transform: translateX(-100%); transition: transform .2s ease; box-shadow: var(--sombra); }
  .app.menu-aberto .lateral { transform: none; }
  .app.menu-aberto::after { content: ""; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 35; }
  .btn-menu { display: inline-flex; }
  .topo { padding: 12px 16px; }
  .topo .so-largo { display: none; }
  .conteudo { padding: 18px 16px 60px; }
  .aviso-faixa { margin: 12px 16px 0; }
  .cal-dia { min-height: 78px; padding: 4px; }
  .cal-post { font-size: 0; padding: 0; height: 6px; border-left-width: 0; border-radius: 4px; }
  .cal-post * { display: none; }
  .cal-dsem { padding: 6px 4px; font-size: 10.5px; text-align: center; }
  .grade-2, .grade-3 { grid-template-columns: 1fr; }
  .modal-fundo { padding: 0; place-items: end center; }
  .modal { max-height: 94vh; border-radius: 18px 18px 0 0; }
  .filtros select, .filtros input { min-width: 0; flex: 1; }
  #toasts { left: 16px; right: 16px; bottom: 16px; }
  .toast { max-width: none; }
}
