/* Interação com as edições da newsletter: ações flutuantes na edição pública e botão "Minhas edições salvas" no acervo. */
.ed-soc, .ed-soc * { box-sizing:border-box }
.ed-soc [hidden], .find-row [hidden] { display:none!important }
.ed-soc { max-width:680px; margin:24px auto 44px; padding:0 16px; font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,Arial,sans-serif; font-size:15px; line-height:1.5; color:#1d1d1f }
/* Sem caixa: cada ação é um botão solto. No desktop eles ficam fixos no canto inferior direito (ver media query abaixo). */
.ed-soc-bar { display:flex; flex-wrap:wrap; align-items:center; justify-content:center; gap:8px; padding:0 }
.ed-soc-btn, .ed-soc-share { position:relative; display:inline-flex; align-items:center; justify-content:center; gap:7px; border:1px solid #e2e5eb; border-radius:999px; background:#fff; color:#33425a; padding:9px 14px; box-shadow:0 4px 14px rgba(0,36,82,.1); font-family:inherit; font-size:14px; font-weight:600; line-height:1; text-decoration:none; cursor:pointer; transition:background .2s,color .2s,transform .2s }
.ed-soc-btn:hover, .ed-soc-share:hover { background:#f1f3f7; transform:translateY(-1px) }
.ed-soc-btn:disabled { opacity:.55; cursor:default }
.ed-soc-btn svg { flex:none }
.ed-soc-btn b { position:absolute; top:-6px; right:-6px; min-width:20px; padding:2px 6px; border-radius:999px; background:#002452; color:#fff; box-shadow:0 1px 4px rgba(0,0,0,.18); font-size:11px; font-weight:700; text-align:center }
.ed-soc-btn.on { background:#002452; border-color:#002452; color:#fff }
.ed-soc-btn.on b { background:#fff; color:#002452 }
.ed-soc-btn.on svg { fill:currentColor }
.ed-soc-sep { display:none }
.ed-soc-msg { flex:1 1 100%; text-align:center; color:#8a1010; font-size:13px }
.ed-soc-comments { margin-top:18px; padding:22px; background:#fff; border:1px solid #e2e5eb; border-radius:18px; box-shadow:0 8px 30px rgba(0,36,82,.04) }
.ed-soc-loading { margin:0; color:#6e6e73; text-align:center }
/* Comentários (mesmos nomes das matérias, sem precisar carregar o conta.css dentro da edição) */
.ed-soc .gc-msg { background:#fde8e8; color:#8a1010; border-radius:8px; padding:8px 12px; font-size:14px; margin:0 0 14px }
.ed-soc .gc-form { display:flex; gap:12px; align-items:flex-start; margin:0 0 16px }
.ed-soc .gc-form-box { flex:1; display:grid; gap:8px; justify-items:end; min-width:0 }
.ed-soc .gc-form textarea { width:100%; box-sizing:border-box; border:1px solid #cfd6e2; border-radius:10px; padding:10px 12px; font:inherit; font-size:15px; resize:vertical; min-height:70px; color:#1d2733; background:#fff }
.ed-soc .gc-form textarea:focus { outline:2px solid #002452; outline-offset:1px }
.ed-soc .gc-btn { display:inline-flex; align-items:center; justify-content:center; padding:9px 18px; border:0; border-radius:999px; background:#002452; color:#fff; font:inherit; font-size:14px; font-weight:700; cursor:pointer }
.ed-soc .gc-btn:disabled { opacity:.6 }
.ed-soc .gc-rules { font-size:12px; color:#7a8290; margin:0 0 18px }
.ed-soc .gc-rules a, .ed-soc .gnews-comments-locked a { color:#002452 }
.ed-soc .gc-empty { color:#6e6e73; margin:0 0 14px }
.ed-soc .gc-list { list-style:none; margin:0; padding:0 }
.ed-soc .gc-item { margin:0 0 18px }
.ed-soc .gc-c { display:flex; gap:12px }
.ed-soc .gc-main { flex:1; min-width:0 }
.ed-soc .gc-head b { color:#0b1b33; font-size:15px }
.ed-soc .gc-when { color:#8592a3; font-size:13px; margin-left:6px }
.ed-soc .gc-body { margin:4px 0 6px; font-size:15px; line-height:1.5; color:#1d2733; overflow-wrap:anywhere }
.ed-soc .gc-actions { display:flex; gap:16px }
.ed-soc .gc-actions button { background:none; border:0; padding:2px 0; color:#55657a; font:inherit; font-size:13px; font-weight:600; cursor:pointer }
.ed-soc .gc-del { color:#a33!important }
.ed-soc .conta-avatar { flex:none; display:inline-flex; align-items:center; justify-content:center; border-radius:50%; background:#002452; color:#fff; font-weight:700; overflow:hidden }
.ed-soc .conta-avatar img { width:100%; height:100%; object-fit:cover }
.ed-soc .gnews-comments-locked { background:#f5f7fb; border-radius:12px; padding:22px; text-align:center; color:#33425a }
.ed-soc .gnews-comments-locked p { margin:8px 0 14px; font-size:14px }
.ed-soc .gc-lock-title { font-size:15px; color:#0b1b33 }
.ed-soc .gc-btns { display:flex; gap:10px; justify-content:center; flex-wrap:wrap }
.ed-soc .gc-btns a { display:inline-flex; align-items:center; justify-content:center; padding:9px 18px; border-radius:999px; border:0; background:#002452; color:#fff!important; font:inherit; font-size:14px; font-weight:700; text-decoration:none!important; cursor:pointer }
.ed-soc .gc-btns a.ghost { background:#fff; color:#002452!important; border:1px solid #c7d1e0 }

/* Desktop: pílulas soltas, com o nome da ação, fixas no bottom right. No celular continua a fileira no fim da edição. */
@media(min-width:721px){
    body.ed-soc-page { padding-bottom:80px }
    .ed-soc { max-width:none; margin:0; padding:0 }
    .ed-soc-bar { position:fixed; right:24px; bottom:24px; z-index:9999; flex-direction:column; align-items:flex-end; flex-wrap:nowrap; gap:8px }
    .ed-soc-btn, .ed-soc-share { min-width:132px; height:42px; padding:0 14px; border-radius:999px; justify-content:flex-start; box-shadow:0 6px 20px rgba(0,36,82,.18); font-size:13px }
    .ed-soc-txt { white-space:nowrap }
    .ed-soc-btn b { top:-4px; right:-4px; min-width:19px; padding:1px 5px; font-size:11px }
    .ed-soc-msg { position:fixed; right:168px; bottom:30px; flex:none; max-width:min(320px,calc(100vw - 200px)); padding:9px 13px; border:1px solid #e2e5eb; border-radius:10px; background:#fff; box-shadow:0 6px 20px rgba(0,36,82,.14); text-align:left }
    .ed-soc-comments { max-width:680px; margin:18px auto 44px }
}
@media(max-width:520px){.ed-soc{margin-top:18px;padding:0 10px}.ed-soc-btn,.ed-soc-share{padding:8px 10px;font-size:13px}.ed-soc-share .ed-soc-txt{display:none}.ed-soc-comments{padding:16px}.ed-soc .gc-form{flex-direction:column}}

/* Modo escuro (o cookie gnews_tema põe a classe no <html>; a edição pública não carrega o cabeçalho do site).
   !important nos fundos dos comentários: o HTML salvo da edição pode trazer estilos próprios de e-mail. */
html.gnews-dark body:has(.ed-soc), body.gnews-dark { background:#292a2d!important; color:#e6e6e6 }
html.gnews-dark .ed-soc, body.gnews-dark .ed-soc { color:#e6e6e6 }
html.gnews-dark .ed-soc-btn, html.gnews-dark .ed-soc-share, body.gnews-dark .ed-soc-btn, body.gnews-dark .ed-soc-share { background:#3c3d41!important; border-color:#55575b; color:#e6e6e6!important; box-shadow:0 6px 20px rgba(0,0,0,.35) }
html.gnews-dark .ed-soc-btn:hover, html.gnews-dark .ed-soc-share:hover, body.gnews-dark .ed-soc-btn:hover, body.gnews-dark .ed-soc-share:hover { background:#4a4c50!important }
html.gnews-dark .ed-soc-btn.on, body.gnews-dark .ed-soc-btn.on { background:#fff!important; border-color:#fff; color:#292a2d!important }
html.gnews-dark .ed-soc-btn.on b, body.gnews-dark .ed-soc-btn.on b { background:#292a2d; color:#fff }
html.gnews-dark .ed-soc-btn b, body.gnews-dark .ed-soc-btn b { background:#55575b; color:#fff; box-shadow:none }
html.gnews-dark .ed-soc-msg, body.gnews-dark .ed-soc-msg { background:#35363a!important; border-color:#55575b; color:#ff9a9a }
html.gnews-dark .ed-soc-comments, body.gnews-dark .ed-soc-comments { background:#35363a!important; border-color:#45474b!important; color:#e6e6e6!important; box-shadow:none }
html.gnews-dark .ed-soc-loading, html.gnews-dark .ed-soc .gc-empty, html.gnews-dark .ed-soc .gc-rules, body.gnews-dark .ed-soc-loading, body.gnews-dark .ed-soc .gc-empty, body.gnews-dark .ed-soc .gc-rules { color:#a3a3a3 }
html.gnews-dark .ed-soc .gc-msg, body.gnews-dark .ed-soc .gc-msg { background:rgba(255,69,58,.14)!important; color:#ff9a9a }
html.gnews-dark .ed-soc .gc-form textarea, body.gnews-dark .ed-soc .gc-form textarea { background:#35363a!important; color:#fff!important; border-color:#55575b!important }
html.gnews-dark .ed-soc .gc-form textarea:focus, body.gnews-dark .ed-soc .gc-form textarea:focus { outline-color:#fff }
html.gnews-dark .ed-soc .gc-btn, body.gnews-dark .ed-soc .gc-btn { background:#fff!important; color:#292a2d!important }
html.gnews-dark .ed-soc .gc-rules a, html.gnews-dark .ed-soc .gnews-comments-locked a, body.gnews-dark .ed-soc .gc-rules a, body.gnews-dark .ed-soc .gnews-comments-locked a { color:#9fbde6 }
html.gnews-dark .ed-soc .gc-head b, html.gnews-dark .ed-soc .gc-body, body.gnews-dark .ed-soc .gc-head b, body.gnews-dark .ed-soc .gc-body { color:#e6e6e6 }
html.gnews-dark .ed-soc .gc-when, body.gnews-dark .ed-soc .gc-when { color:#86868b }
html.gnews-dark .ed-soc .gc-actions button, body.gnews-dark .ed-soc .gc-actions button { color:#9fbde6 }
html.gnews-dark .ed-soc .gc-del, body.gnews-dark .ed-soc .gc-del { color:#ff6b6b!important }
html.gnews-dark .ed-soc .conta-avatar, body.gnews-dark .ed-soc .conta-avatar { background:#55575b; color:#fff }
html.gnews-dark .ed-soc .gnews-comments-locked, body.gnews-dark .ed-soc .gnews-comments-locked { background:#3c3d41!important; color:#e6e6e6!important }
html.gnews-dark .ed-soc .gc-lock-title, body.gnews-dark .ed-soc .gc-lock-title { color:#fff }
html.gnews-dark .ed-soc .gc-btns a, body.gnews-dark .ed-soc .gc-btns a { background:#fff!important; color:#292a2d!important; border-color:#fff }
html.gnews-dark .ed-soc .gc-btns a.ghost, body.gnews-dark .ed-soc .gc-btns a.ghost { background:transparent!important; color:#fff!important; border-color:#55575b }

/* Acervo (/newsletter/edicoes): o botão de edições salvas entra ao lado da busca, só para quem está logado. */
.find-row { display:flex; align-items:center; justify-content:center; gap:10px; flex-wrap:wrap; max-width:900px; margin:30px auto 0 }
.find-row .find { flex:1 1 420px; max-width:520px; margin:0 }
.ed-saved { display:inline-flex; align-items:center; gap:8px; min-height:50px; padding:0 17px; border:1px solid var(--line); border-radius:999px; background:var(--card); color:var(--ink); font:500 14px var(--sans); text-decoration:none; transition:border-color .2s,box-shadow .2s }
.ed-saved:hover { border-color:var(--acc); box-shadow:0 0 0 4px var(--ring) }
.ed-saved svg { flex:none; width:17px; height:17px; color:var(--acc) }
html.gnews-dark .ed-saved { background:#35363a; border-color:#45474b; color:#e6e6e6 }
html.gnews-dark .ed-saved:hover { border-color:#fff; box-shadow:0 0 0 4px rgba(255,255,255,.12) }
html.gnews-dark .ed-saved svg { color:#fff }
@media(max-width:600px){.find-row{gap:8px}.find-row .find{flex:1 1 100%}.ed-saved{min-height:44px}}
