/* Fundo contínuo e imagens por assunto; todos os elementos são decorativos. */
:root { --scene-opacity:.075; --atmosphere-opacity:.08; }
html[data-background="destaque"] { --scene-opacity:.12; --atmosphere-opacity:.14; }
html[data-background="off"] .ambient-scene,html[data-background="off"] .page-atmosphere,html[data-background="off"] .context-scene { display:none; }
.page-atmosphere { position:fixed; z-index:0; inset:0; overflow:hidden; pointer-events:none; }
.page-atmosphere > img { width:100%; height:100%; max-width:none; object-fit:cover; object-position:center bottom; opacity:var(--atmosphere-opacity); }
.page-atmosphere::after { content:""; position:absolute; inset:0; background:none; }
.scenic-section { position:relative; isolation:isolate; }
.scenic-section > .container { position:relative; z-index:1; }
.ambient-scene { position:absolute; z-index:0; inset:0; overflow:hidden; contain:paint; pointer-events:none; }
.ambient-image { position:absolute; width:min(1000px,92vw); height:750px; max-width:none; top:8%; right:-18%; object-fit:cover; opacity:var(--scene-opacity); filter:grayscale(.35) blur(1px); mix-blend-mode:multiply; mask-image:radial-gradient(ellipse at center,#000 12%,transparent 70%); -webkit-mask-image:radial-gradient(ellipse at center,#000 12%,transparent 70%); transform:translate3d(var(--scene-x,0px),var(--scene-y,0px),0) scale(1.04); transition:opacity .4s ease,transform .7s ease-out; }
.ambient-scene[data-in-view="true"] .ambient-image { will-change:transform; }
.ambient-left .ambient-image { left:-20%; right:auto; }
.ambient-top .ambient-image { top:0; }
.ambient-dark .ambient-image { top:-60px; right:-12%; }
.ambient-halo { position:absolute; inset:0; background:radial-gradient(ellipse 350px 280px at var(--halo-x,80%) var(--halo-y,30%),var(--accent-soft),transparent 90%); opacity:.035; }
.context-scene { position:absolute; z-index:0; inset:0 -8vw; overflow:hidden; pointer-events:none; }
.context-image { position:absolute; width:min(700px,85vw); height:650px; max-width:none; right:-10%; top:70px; object-fit:contain; opacity:calc(var(--scene-opacity) * .8); filter:grayscale(.35) blur(2px); mix-blend-mode:multiply; mask-image:radial-gradient(ellipse at center,#000 12%,transparent 68%); -webkit-mask-image:radial-gradient(ellipse at center,#000 12%,transparent 68%); }
.reader-technique:nth-child(even) .context-image { right:auto; left:-10%; }
html[data-background-motion="off"] .ambient-image { transform:none; transition:opacity .3s ease; will-change:auto; }
.background-controls { margin:18px 0 0; padding:17px 0 0; border:0; border-top:1px solid var(--border); }
.background-controls legend { float:left; width:100%; margin-bottom:12px; padding:0; font-size:.82rem; font-weight:700; color:var(--primary); }
.background-controls > div { display:flex; clear:both; flex-wrap:wrap; gap:6px; }
.background-controls button { padding:7px 9px; border:1px solid var(--border); border-radius:6px; color:var(--primary); background:transparent; font-size:.73rem; }
.background-controls button[aria-pressed="true"] { color:var(--inverse); background:var(--primary); border-color:var(--primary); }
.motion-choice { display:flex; align-items:center; gap:9px; margin-top:15px; color:var(--primary); font-size:.8rem; }
.motion-choice input { width:18px; height:18px; margin:0; accent-color:var(--primary); }
.motion-choice:has(input:disabled) { opacity:.6; }
#background-status { margin:9px 0 0; color:var(--muted); font-size:.71rem; line-height:1.6; }

@media (max-width:700px) {
  .page-atmosphere > img { object-position:82% center; }
  .page-atmosphere::after { background:none; }
  .ambient-image,.ambient-left .ambient-image,.ambient-top .ambient-image,.ambient-dark .ambient-image { width:620px; height:700px; top:40px; right:-260px; left:auto; opacity:calc(var(--scene-opacity) * .75); }
  .ambient-left .ambient-image { left:-260px; right:auto; }
  .context-scene { inset:0 -10px; }
  .context-image,.reader-technique:nth-child(even) .context-image { width:480px; height:650px; top:130px; right:-190px; left:auto; opacity:calc(var(--scene-opacity) * .65); }
  .ambient-halo { display:none; }
}
@media (prefers-reduced-motion:reduce) { .ambient-image { transform:none !important; transition:none !important; will-change:auto !important; } }
@media print { .page-atmosphere,.ambient-scene,.context-scene { display:none !important; } }
