/* =========================================================
   A CASA MUDA — folha de estilo única
   Todas as páginas usam este arquivo. Mude aqui, muda em tudo.
   ========================================================= */

/* 1. FONTES ------------------------------------------------ */
/* (WOFF2 = formato compacto para web; as .OTF originais estão em originais/fonts) */
@font-face { font-family: 'Now'; src: url('../fonts/now-thin.woff2') format('woff2');    font-weight: 100; font-display: swap; }
@font-face { font-family: 'Now'; src: url('../fonts/now-light.woff2') format('woff2');   font-weight: 300; font-display: swap; }
@font-face { font-family: 'Now'; src: url('../fonts/now-regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Now'; src: url('../fonts/now-medium.woff2') format('woff2');  font-weight: 500; font-display: swap; }
@font-face { font-family: 'Now'; src: url('../fonts/now-bold.woff2') format('woff2');    font-weight: 700; font-display: swap; }
@font-face { font-family: 'Now'; src: url('../fonts/now-black.woff2') format('woff2');   font-weight: 900; font-display: swap; }
@font-face { font-family: 'MightySouly'; src: url('../fonts/mighty-souly.woff2') format('woff2'); font-display: swap; }

/* 2. CORES E MEDIDAS -------------------------------------- */
:root {
    --marrom:   #27150c;
    --creme:    #ede6bb;
    --vermelho: #ef4526;

    --fundo: var(--creme);
    --texto: var(--marrom);
    --destaque: var(--vermelho);

    --fonte: 'Now', system-ui, sans-serif;
    --fonte-titulo: 'MightySouly', Georgia, serif;

    --corpo: clamp(17px, 2.2vmin, 23px);
    --menu: clamp(11px, 1.7vmin, 16px);
    --largura-texto: 65ch;
    --moldura: 2vh;
}

/* tema escuro (home): fundo marrom, texto creme */
.tema-escuro { --fundo: var(--marrom); --texto: var(--creme); }

/* 3. RESET ------------------------------------------------- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html { background: var(--fundo); }
body {
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--fundo);
    color: var(--texto);
    font-family: var(--fonte);
    font-weight: 400;
    position: relative;
    overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }

.so-leitor h1, .so-leitor h2 { font-weight: 900; }  /* reaproveita a fonte Black, sem baixar a Bold */
.so-leitor {
    position: absolute !important; width: 1px; height: 1px;
    overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* 4. MOLDURAS (faixas coloridas topo/base) ---------------- */
.moldura { position: fixed; left: 0; width: 100%; height: var(--moldura); z-index: 100; pointer-events: none; }
.moldura-topo { top: 0; }
.moldura-base { bottom: 0; }
.moldura img { width: 100%; height: 100%; object-fit: cover; }

/* 5. ASSINATURA (canto inferior direito) ------------------ */
.assinatura {
    position: fixed; bottom: 5vmin; right: 5vmin;
    width: 25vmin; max-width: 220px;
    z-index: 10; pointer-events: none;
}
/* nas páginas de texto a assinatura não fica parada na tela: ela fecha a página,
   no fim do conteúdo, à direita (assim nunca cobre o texto) */
.tema-claro .assinatura { position: static; width: 18vmin; max-width: 170px; margin: 0 10vw calc(var(--moldura) + 5vh) auto; }

/* 6. MENU (quadrados sólidos) ----------------------------- */
.menu { display: flex; flex-wrap: wrap; gap: 1.2vmin; align-items: stretch; }
.menu a {
    font-weight: 900;
    font-size: var(--menu);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-decoration: none;
    white-space: nowrap;
    color: var(--creme);
    background: var(--marrom);
    padding: 1.4vmin 2.4vmin;
    display: inline-flex; align-items: center;
    transition: background-color 0.3s ease, color 0.3s ease;
}
.menu a:hover, .menu a:focus-visible { background: var(--destaque); color: #fff; }
.menu a[aria-current="page"] { background: var(--destaque); color: #fff; }
/* olho (volta para a home) */
.menu-casa {
    display: inline-flex; align-items: center; background: var(--marrom);
    padding: 0.8vmin 1.2vmin; transition: background-color 0.3s ease;
}
.menu-casa:hover, .menu-casa:focus-visible { background: var(--destaque); }
.menu-casa img { width: calc(var(--menu) * 1.9); height: calc(var(--menu) * 1.9); }
.topo-esq { display: flex; flex-wrap: wrap; gap: 1.2vmin; align-items: stretch; position: relative; }

/* submenu (ex.: A Casa Muda ▾) — abre e fecha sem JavaScript */
.submenu { position: relative; }
.submenu > summary {
    list-style: none; cursor: pointer; user-select: none;
    font-weight: 900; font-size: var(--menu); letter-spacing: 0.1em; text-transform: uppercase; white-space: nowrap;
    color: var(--creme); background: var(--marrom);
    padding: 1.4vmin 2.4vmin; height: 100%;
    display: inline-flex; align-items: center; gap: 0.6em;
    transition: background-color 0.3s ease, color 0.3s ease;
}
.submenu > summary::-webkit-details-marker { display: none; }
.submenu > summary::after {
    content: ""; width: 0.45em; height: 0.45em; margin-top: -0.25em;
    border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
    transform: rotate(45deg); transition: transform 0.2s ease;
}
.submenu[open] > summary::after { transform: rotate(-135deg); margin-top: 0.2em; }
.submenu > summary:hover, .submenu[open] > summary, .submenu.atual > summary { background: var(--destaque); color: #fff; }
.submenu-lista {
    position: absolute; top: 100%; left: 0; z-index: 400;
    min-width: 100%; width: max-content; padding: 6px 0;
    background: var(--marrom);
    display: flex; flex-direction: column;
}
.menu .submenu-lista a { background: transparent; padding: 1.2vmin 2.4vmin; }
.menu .submenu-lista a:hover { background: rgba(239, 69, 38, 0.3); }
.menu .submenu-lista a[aria-current="page"] { background: transparent; color: var(--destaque); }

/* botão "Menu" (só aparece no celular; funciona sem JavaScript).
   No computador o menu já fica aberto: a chave sai de cena. */
.menu-chave { display: none; }
.menu-botao { display: none; }

/* 7. HOME ------------------------------------------------- */
.tema-escuro.home { height: 100vh; height: 100dvh; overflow: hidden; display: flex; justify-content: center; align-items: center; }
html:has(> body.home) { overflow: hidden; height: 100%; }

/* o fundo fica numa camada fixa do tamanho da tela, que corta o excesso:
   assim a página nunca fica maior que a tela e não "escorrega" ao atualizar */
.fundo-giratorio {
    position: fixed; inset: 0;
    overflow: hidden;
    z-index: 1; pointer-events: none;
}
.fundo-giratorio img {
    position: absolute; top: 50%; left: 50%;
    /* 150vmax basta para cobrir a tela girando (a diagonal nunca passa de 1,42vmax).
       O bg-home.svg foi recortado no centro para manter o mesmo zoom de antes (250vmax):
       camada menor = o celular consegue girar sem estourar a memória de vídeo */
    width: 150vmax; height: 150vmax; max-width: none;
    margin: -75vmax 0 0 -75vmax;
    animation: girar 60s linear infinite;
}
@keyframes girar { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .fundo-giratorio img { animation: none; } }

.menu-home { position: fixed; top: 5vmin; left: 0; width: 100%; display: flex; justify-content: center; padding: 0 5vw; z-index: 10; }
.menu-home .menu { justify-content: center; }
.home-centro { position: relative; z-index: 5; width: 80vmin; height: 80vmin; display: flex; justify-content: center; align-items: center; pointer-events: none; }
.home-centro > img { width: 100%; height: 100%; object-fit: contain; }

/* 8. TOPO DAS PÁGINAS INTERNAS ---------------------------- */
.topo {
    display: flex; justify-content: space-between; align-items: flex-start; gap: 2vmin;
    padding: calc(var(--moldura) + 3vh) 5vw 0;
    position: relative; z-index: 150;
}

/* RSS (ao lado do Arquivo, nas páginas do blog) */
.topo-blog { display: flex; gap: 1.2vmin; align-items: flex-start; flex-shrink: 0; }
.botao-rss {
    display: inline-flex; align-items: center; gap: 0.5em;
    font-weight: 900; font-size: var(--menu); letter-spacing: 0.1em; text-transform: uppercase; text-decoration: none;
    color: var(--texto); border: 2px solid var(--texto);
    padding: calc(1.4vmin - 2px) calc(2.4vmin - 2px);
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}
.botao-rss svg { width: 1.1em; height: 1.1em; fill: currentColor; }
.botao-rss:hover, .botao-rss:focus-visible { background: var(--destaque); border-color: var(--destaque); color: #fff; }

/* 9. ARQUIVO (funciona sem JavaScript: <details>) -------- */
.arquivo { position: relative; flex-shrink: 0; }
.arquivo > summary {
    list-style: none; cursor: pointer;
    font-weight: 900; font-size: var(--menu); letter-spacing: 0.1em; text-transform: uppercase;
    color: var(--creme); background: var(--marrom);
    padding: 1.4vmin 2.4vmin;
    transition: background-color 0.3s ease;
}
.arquivo > summary::-webkit-details-marker { display: none; }
.arquivo > summary:hover, .arquivo[open] > summary { background: var(--destaque); color: #fff; }
.arquivo-lista {
    position: absolute; right: 0; top: 100%;
    width: 300px; max-width: 85vw; max-height: 70vh; overflow-y: auto;
    padding: 20px; background: var(--marrom); color: var(--creme);
}
.arquivo-lista details details { margin-left: 15px; }
.arquivo-lista summary {
    cursor: pointer; list-style: none;
    font-weight: 900; text-transform: uppercase; letter-spacing: 0.05em; font-size: 14px;
    margin-top: 10px; padding: 5px 0;
    border-bottom: 1px solid rgba(237, 230, 187, 0.2);
}
.arquivo-lista summary::-webkit-details-marker { display: none; }
.arquivo-lista a { display: block; padding: 8px 0; font-size: 13px; text-decoration: none; color: var(--creme); }
.arquivo-lista a:hover, .arquivo-lista a[aria-current="page"] { color: var(--destaque); }

/* 10. TEXTO (manifesto, posts, páginas) ------------------- */
.pagina { padding: 8vh 10vw 6vh; display: flex; flex-direction: column; align-items: flex-start; }
.texto { max-width: var(--largura-texto); width: 100%; }

.texto h1 {
    font-family: var(--fonte-titulo); font-weight: 700;
    font-size: clamp(34px, 7vmin, 80px); line-height: 1.1; letter-spacing: -0.01em;
    margin-bottom: 6vh;
}
.texto h1 a { text-decoration: none; }
.texto h2 {
    font-weight: 900; font-size: clamp(20px, 3.5vmin, 32px);
    text-transform: uppercase; letter-spacing: 0.1em;
    margin: 6vh 0 2vh;
}
.texto h3 { font-weight: 900; font-size: calc(var(--corpo) * 1.1); margin: 4vh 0 1.5vh; }
.texto p, .texto li { font-size: var(--corpo); line-height: 1.6; }
/* texto justificado; a hifenização (português) evita buracos entre as palavras */
.texto p, .texto li, .texto blockquote { text-align: justify; -webkit-hyphens: auto; hyphens: auto; }
.texto p { margin-bottom: 3vh; }
.texto ul, .texto ol { margin: 0 0 3vh 1.2em; }
.texto li { margin-bottom: 1vh; }
.texto strong { font-weight: 900; }
.texto a { text-decoration-thickness: 2px; text-underline-offset: 3px; }
.texto a:hover { color: var(--destaque); }
.texto blockquote { border-left: 4px solid var(--destaque); padding-left: 1.2em; margin: 0 0 3vh; }
.texto hr { border: 0; border-top: 2px solid var(--texto); margin: 6vh 0; width: 30%; }
.texto img { margin: 4vh 0; }
.texto code { font-size: 0.9em; background: rgba(39, 21, 12, 0.08); padding: 0 0.3em; }
/* parágrafo que é só um endereço (ex.: o feed na página do RSS): caixa para copiar */
.texto p > code:only-child { display: inline-block; font-size: 1em; padding: 0.6em 0.9em; background: var(--marrom); color: var(--creme); word-break: break-all; user-select: all; }

/* classes que você pode usar no Markdown com {.classe} no fim do parágrafo */
.texto .forte { font-weight: 900; margin-top: 5vh; margin-bottom: 2vh; }
.texto .aviso {
    font-size: calc(var(--corpo) * 0.85);
    border: 2px dashed var(--texto); padding: 1.2em 1.4em;
    margin-bottom: 5vh;
}
.texto .nota { font-style: italic; opacity: 0.8; }
/* caixas: no Markdown, escreva  > [!aviso] texto  (o formato de "callout" do Obsidian) */
.texto .caixa {
    font-size: calc(var(--corpo) * 0.85);
    border: 2px dashed var(--texto); padding: 1.2em 1.4em 0.2em;
    margin-bottom: 5vh;
}
.texto .caixa p { font-size: inherit; margin-bottom: 1em; }
.texto .caixa-nota, .texto .caixa-info { border-style: solid; }
/* FRASE DE CARTAZ: no Markdown,  > [!frase]  e a frase na linha de baixo (começando com >).
   Uma frase grande entre dois blocos de texto, como num cartaz. */
.texto .caixa-frase {
    border: 0; padding: 0; margin: 7vh 0;
    border-left: 6px solid var(--destaque); padding-left: 0.6em;
}
.texto .caixa-frase p {
    font-family: var(--fonte-titulo); font-weight: 700;
    font-size: clamp(26px, 4vmin, 46px); line-height: 1.08; letter-spacing: 0.01em;
    text-align: left; -webkit-hyphens: manual; hyphens: manual;
    margin: 0 0 0.4em; color: var(--texto);
}
.texto .caixa-frase p:last-child { margin-bottom: 0; }
/* imagem com largura definida (![[foto.jpg|500]]) fica centralizada */
.texto img[width] { margin-left: auto; margin-right: auto; }
/* capa de disco: sempre quadrada (parágrafo da imagem marcado com {.capa}) */
.texto .capa { text-align: center; }
.texto .capa img { aspect-ratio: 1 / 1; object-fit: cover; height: auto; }
/* tabelas */
.texto .tabela { overflow-x: auto; margin: 0 0 4vh; }
.texto table { border-collapse: collapse; font-size: calc(var(--corpo) * 0.85); min-width: 60%; }
.texto th, .texto td { border-bottom: 1px solid rgba(39, 21, 12, 0.3); padding: 0.6em 1em 0.6em 0; text-align: left; vertical-align: top; }
.texto th { font-weight: 900; text-transform: uppercase; letter-spacing: 0.08em; font-size: 0.8em; border-bottom: 2px solid var(--texto); }
/* ==realce== e listas de tarefa */
.texto mark { background: rgba(239, 69, 38, 0.25); color: inherit; padding: 0 0.15em; }
.texto li.tarefa { list-style: none; margin-left: -1.2em; }
.texto .figura img { width: 100%; max-width: 520px; margin: 2vh auto 4vh; }

/* 11. POSTS ----------------------------------------------- */
.post-data { font-size: var(--menu) !important; font-weight: 900; text-transform: uppercase; letter-spacing: 0.15em; margin-bottom: 2vh !important; opacity: 0.75; }
.post-assinatura { margin-top: 6vh; }
.post-assinatura .forte { margin-bottom: 2vh; }
.texto .post-assinatura img { width: 15vmin; max-width: 150px; height: auto; margin: 0; }

.lista-posts { margin-top: 10vh; }
.lista-posts ul { list-style: none; margin-left: 0; }
.lista-posts li { display: flex; gap: 1.2em; align-items: baseline; padding: 1.2vh 0; border-bottom: 1px solid rgba(39, 21, 12, 0.2); margin: 0; }
.lista-posts time { font-size: var(--menu); font-weight: 900; letter-spacing: 0.1em; white-space: nowrap; opacity: 0.7; }
.lista-posts a { text-decoration: none; }

/* 12. BOTÕES ---------------------------------------------- */
.nav-posts { margin-top: 8vh; display: flex; flex-wrap: wrap; gap: 20px; }
.nav-posts a {
    font-weight: 900; font-size: 14px; text-transform: uppercase; letter-spacing: 0.05em;
    color: var(--texto); text-decoration: none;
    border: 2px solid var(--texto); padding: 10px 20px;
    transition: 0.3s;
}
.nav-posts a:hover { background: var(--destaque); border-color: var(--destaque); color: #fff; }

.botao a, a.botao {
    display: inline-block;
    font-weight: 900; font-size: clamp(14px, 1.8vmin, 20px);
    text-transform: uppercase; letter-spacing: 0.2em; text-decoration: none;
    color: var(--creme); background: var(--marrom);
    padding: 2.2vmin 5vmin;
    transition: all 0.3s ease;
}
.botao a:hover, a.botao:hover { background: var(--destaque); color: #fff; }

/* 13. PÁGINA CENTRALIZADA (404) --------------------------- */
.centro {
    min-height: 100dvh; display: flex; flex-direction: column; justify-content: center; align-items: center;
    text-align: center; padding: 10vh 5vw;
}
.centro-icone { width: clamp(80px, 12vmin, 140px); margin-bottom: 4vh; }
.centro h1 { font-weight: 900; font-size: clamp(32px, 8vmin, 100px); text-transform: uppercase; letter-spacing: -0.02em; line-height: 1.1; margin-bottom: 2vh; }
.centro p a {
    display: inline-block; font-weight: 900; font-size: clamp(14px, 1.8vmin, 20px);
    text-transform: uppercase; letter-spacing: 0.2em; text-decoration: none;
    color: var(--creme); background: var(--marrom); padding: 2.2vmin 5vmin; transition: all 0.3s ease;
}
.centro p a:hover { background: var(--destaque); color: #fff; }
.centro p { font-size: clamp(16px, 2.2vmin, 24px); max-width: 65ch; line-height: 1.6; margin: 0 auto 6vh; }

/* 14. TAROT (cartas) ------------------------------------ */
:root { --verde: #22502f; --vinho: #8e1b1b; --azul: #2b4257; }
.largo .texto { max-width: 1100px; }
.largo .texto > p, .largo .texto > ul, .largo .texto > .caixa { max-width: var(--largura-texto); }

.sumario { display: flex; flex-wrap: wrap; gap: 1.2vmin; margin: 2vh 0 4vh; }
.sumario a {
    font-weight: 900; font-size: var(--menu); letter-spacing: 0.1em; text-transform: uppercase; text-decoration: none;
    border: 2px solid var(--texto); padding: 1.2vmin 2vmin;
}
.sumario a span { opacity: 0.6; margin-left: 0.4em; }
.sumario a:hover { background: var(--destaque); border-color: var(--destaque); color: #fff; }

.legenda-cores { list-style: none; margin-left: 0 !important; display: flex; flex-wrap: wrap; gap: 0.4em 1.6em; }
.legenda-cores li { font-size: calc(var(--corpo) * 0.85) !important; display: flex; align-items: center; gap: 0.5em; margin: 0; }
.cor { width: 1.6em; height: 0.8em; display: inline-block; background: var(--faixa); }

.cor-verde     { --faixa: var(--verde); }
.cor-vermelho  { --faixa: var(--vinho); }
.cor-azul      { --faixa: var(--azul); }
.cor-ponte     { --faixa: linear-gradient(90deg, var(--verde) 50%, var(--vinho) 50%); }
.cor-indefinida{ --faixa: repeating-linear-gradient(45deg, var(--marrom) 0 6px, transparent 6px 12px); }

.eixo { margin: 7vh 0 4vh; }
.texto .eixo h3 {
    font-family: var(--fonte-titulo); font-weight: 700; font-size: clamp(26px, 4.5vmin, 46px);
    line-height: 1.1; margin: 0 0 1vh;
}
.eixo h3 span { color: var(--destaque); font-family: var(--fonte); font-weight: 900; }
.texto .eixo-tese { font-style: italic; opacity: 0.85; max-width: var(--largura-texto); }

.cartas { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; margin: 2vh 0 5vh; }
.cartas-pequenas { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.carta {
    background: rgba(39, 21, 12, 0.05);
    border: 2px solid var(--marrom);
    padding: 22px 22px 8px;
    position: relative;
}
.carta[class*="cor-"] { border-top: 0; padding-top: 30px; }
.carta[class*="cor-"]::before { content: ""; position: absolute; left: -2px; right: -2px; top: 0; height: 10px; background: var(--faixa); }
.texto .carta h4 {
    font-family: var(--fonte-titulo); font-weight: 700;
    font-size: clamp(24px, 3.4vmin, 36px); line-height: 1.05; margin-bottom: 1.5vh;
}
.cartas-pequenas .carta h4 { font-size: clamp(19px, 2.4vmin, 26px); }
.texto .carta p { font-size: calc(var(--corpo) * 0.88); margin-bottom: 2vh; }
.texto .carta .carta-tipo {
    font-size: 11px; font-weight: 900; text-transform: uppercase; letter-spacing: 0.15em;
    opacity: 0.7; margin-bottom: 1vh;
}
/* a cor e o tipo da carta continuam no Markdown (é deles que sai a faixa colorida no topo),
   mas o texto da etiqueta não aparece */
.texto .carta .carta-tipo { display: none; }
/* carta ainda sem nome ("+10 a revelar"): mesma caixa das outras, com borda tracejada */
.carta-oculta { border-style: dashed; background: transparent; }
.texto .carta-oculta .carta-texto p { font-style: italic; text-align: center; }

/* arte da carta (ou o verso, com "arte a revelar", enquanto a arte não existe) */
.carta.com-arte { display: grid; grid-template-columns: minmax(120px, 36%) 1fr; gap: 22px; align-items: start; align-content: start; }
.carta-arte {
    position: relative; display: block;
    aspect-ratio: 547.28 / 793.79;
    margin-bottom: 14px;
}
.texto .carta-arte img { width: 100%; height: 100%; object-fit: cover; margin: 0; }
.carta-arte-aviso {
    position: absolute; left: 50%; bottom: 9%; transform: translateX(-50%);
    font-weight: 900; font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; white-space: nowrap;
    color: var(--creme); background: var(--marrom); padding: 4px 8px;
}
a.carta-arte:hover img { filter: brightness(1.08); }
/* cartas pequenas: arte em cima */
.cartas-pequenas .carta.com-arte { grid-template-columns: 1fr; gap: 0; }
.cartas-pequenas .carta-arte { width: 72%; margin: 0 auto 16px; }

/* dentro das cartas o texto é curto e a coluna é estreita: alinhado à esquerda (justificado abriria buracos) */
.texto .carta p, .texto .carta li { text-align: left; -webkit-hyphens: manual; hyphens: manual; }
.texto .carta-mais { margin: 0.8em 0 0; font-weight: 900; font-size: calc(var(--corpo) * 0.85); letter-spacing: 0.06em; text-transform: uppercase; }
.texto .carta-mais a { text-decoration: none; }
.texto .carta-mais a:hover { color: var(--destaque); }
/* nome da carta é link para a página dela */
.texto .carta h4 a { text-decoration: none; }
.texto .carta h4 a:hover { color: var(--destaque); }

/* RETRATO: página com uma imagem em pé ao lado do texto ("retrato:" no cabeçalho).
   Celular e telas em pé: a imagem vira capa no topo, fica parada, e o texto sobe por cima. */
.retrato { position: sticky; top: 0; z-index: 0; width: 100%; height: 64vh; height: 64svh; background: var(--marrom); }
.retrato img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; }
.retrato-inteira img { object-fit: contain; padding: 4vmin; }
.com-retrato .pagina { position: relative; z-index: 1; background: var(--fundo); }
.com-retrato .topo { background: var(--fundo); }
/* computador e telas deitadas: a imagem fixa ocupa a metade esquerda, o texto a direita */
@media (orientation: landscape) and (min-width: 900px) {
    .com-retrato .retrato { position: fixed; top: 0; left: 0; width: 50vw; height: 100vh; }
    .com-retrato .retrato-inteira img { padding: calc(var(--moldura) + 4vh) 4vw; }
    .com-retrato .topo, .com-retrato .pagina { margin-left: 50vw; }
    .com-retrato .topo { padding-left: 5vw; padding-right: 4vw; background: none; }
    .com-retrato .pagina { padding-left: 5vw; padding-right: 5vw; background: none; }
}

/* GALERIA: "fotos:" no cabeçalho. Fotos sempre quadradas no lugar do retrato,
   com setas que trocam a foto. Sem JavaScript: cada foto tem um botão de rádio escondido. */
.retrato-galeria { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 2.5vh; height: auto; padding: 6vmin 6vmin 4vmin; }
.galeria-escolha { position: absolute; opacity: 0; pointer-events: none; }
.galeria-fotos { width: 100%; max-width: 72vh; }
.galeria-fotos img { display: none; width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; margin: 0; }
#foto-1:checked ~ .galeria-fotos .foto-1,
#foto-2:checked ~ .galeria-fotos .foto-2,
#foto-3:checked ~ .galeria-fotos .foto-3,
#foto-4:checked ~ .galeria-fotos .foto-4,
#foto-5:checked ~ .galeria-fotos .foto-5,
#foto-6:checked ~ .galeria-fotos .foto-6,
#foto-7:checked ~ .galeria-fotos .foto-7,
#foto-8:checked ~ .galeria-fotos .foto-8,
#foto-9:checked ~ .galeria-fotos .foto-9,
#foto-10:checked ~ .galeria-fotos .foto-10,
#foto-11:checked ~ .galeria-fotos .foto-11,
#foto-12:checked ~ .galeria-fotos .foto-12 { display: block; }
.galeria-controle { display: flex; align-items: center; gap: 1.2em; color: var(--creme); font-weight: 900; font-size: var(--menu); letter-spacing: 0.1em; }
.galeria-controle > * { display: none; }
#foto-1:checked ~ .galeria-controle .ant-1, #foto-1:checked ~ .galeria-controle .conta-1, #foto-1:checked ~ .galeria-controle .prox-1,
#foto-2:checked ~ .galeria-controle .ant-2, #foto-2:checked ~ .galeria-controle .conta-2, #foto-2:checked ~ .galeria-controle .prox-2,
#foto-3:checked ~ .galeria-controle .ant-3, #foto-3:checked ~ .galeria-controle .conta-3, #foto-3:checked ~ .galeria-controle .prox-3,
#foto-4:checked ~ .galeria-controle .ant-4, #foto-4:checked ~ .galeria-controle .conta-4, #foto-4:checked ~ .galeria-controle .prox-4,
#foto-5:checked ~ .galeria-controle .ant-5, #foto-5:checked ~ .galeria-controle .conta-5, #foto-5:checked ~ .galeria-controle .prox-5,
#foto-6:checked ~ .galeria-controle .ant-6, #foto-6:checked ~ .galeria-controle .conta-6, #foto-6:checked ~ .galeria-controle .prox-6,
#foto-7:checked ~ .galeria-controle .ant-7, #foto-7:checked ~ .galeria-controle .conta-7, #foto-7:checked ~ .galeria-controle .prox-7,
#foto-8:checked ~ .galeria-controle .ant-8, #foto-8:checked ~ .galeria-controle .conta-8, #foto-8:checked ~ .galeria-controle .prox-8,
#foto-9:checked ~ .galeria-controle .ant-9, #foto-9:checked ~ .galeria-controle .conta-9, #foto-9:checked ~ .galeria-controle .prox-9,
#foto-10:checked ~ .galeria-controle .ant-10, #foto-10:checked ~ .galeria-controle .conta-10, #foto-10:checked ~ .galeria-controle .prox-10,
#foto-11:checked ~ .galeria-controle .ant-11, #foto-11:checked ~ .galeria-controle .conta-11, #foto-11:checked ~ .galeria-controle .prox-11,
#foto-12:checked ~ .galeria-controle .ant-12, #foto-12:checked ~ .galeria-controle .conta-12, #foto-12:checked ~ .galeria-controle .prox-12 { display: inline-flex; }
.galeria-seta { align-items: center; justify-content: center; width: 2.6em; height: 2.6em; cursor: pointer; user-select: none; background: var(--creme); color: var(--marrom); font-size: 1.1em; transition: background-color 0.2s ease, color 0.2s ease; }
.galeria-seta:hover { background: var(--destaque); color: #fff; }
.galeria-escolha:focus-visible ~ .galeria-controle .galeria-seta { outline: 2px solid var(--destaque); outline-offset: 2px; }
@media (orientation: landscape) and (min-width: 900px) {
    .com-retrato .retrato-galeria { height: 100vh; padding: calc(var(--moldura) + 6vh) 5vw; }
    .retrato-galeria .galeria-fotos { max-width: min(40vw, 72vh); }
}

/* ACERVO: grade de peças, todas com a foto quadrada ("modelo: acervo") */
.acervo { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(200px, 40vw), 1fr)); gap: 4vh 4vw; margin: 4vh 0; }
.texto .obra { display: flex; flex-direction: column; gap: 0.3em; text-decoration: none; color: var(--texto); }
.obra-foto { display: block; aspect-ratio: 1 / 1; background: var(--marrom); overflow: hidden; margin-bottom: 0.5em; }
.texto .obra-foto img { width: 100%; height: 100%; object-fit: cover; margin: 0; transition: transform 0.4s ease; }
.obra:hover .obra-foto img { transform: scale(1.03); }
.obra-nome { font-weight: 900; text-transform: uppercase; letter-spacing: 0.05em; font-size: calc(var(--corpo) * 0.9); }
.obra:hover .obra-nome { color: var(--destaque); }
.obra-info { font-style: italic; font-size: calc(var(--corpo) * 0.8); opacity: 0.8; }
.obra-situacao { font-weight: 900; font-size: calc(var(--corpo) * 0.7); text-transform: uppercase; letter-spacing: 0.12em; color: var(--destaque); }
.obra-vendida .obra-situacao { color: var(--texto); opacity: 0.6; }
.texto .obra-preco { font-weight: 900; font-size: calc(var(--corpo) * 1.2); }

/* 15. AGENDA ---------------------------------------------- */
.evento {
    border-left: 6px solid var(--destaque);
    padding: 0.4em 0 0.2em 1.2em;
    margin: 0 0 6vh;
    max-width: var(--largura-texto);
}
.texto .evento-data {
    font-weight: 900; text-transform: uppercase; letter-spacing: 0.12em;
    font-size: var(--menu) !important; margin-bottom: 1vh;
}
.texto .evento h3 {
    font-family: var(--fonte-titulo); font-weight: 700;
    font-size: clamp(26px, 4.2vmin, 42px); line-height: 1.1; margin: 0 0 1vh;
}
.texto .evento-local { font-weight: 900; margin-bottom: 2vh; }
.texto .evento-extra { font-size: calc(var(--corpo) * 0.9); }
.evento-passado { border-left-color: var(--marrom); opacity: 0.7; }
/* cartaz do evento: qualquer formato (em pé, deitado, quadrado) mantém a proporção,
   sem cortar; só é limitado em largura e altura para não tomar a tela */
.texto .evento-cartaz { margin: 0 0 2vh; }
.texto .evento-cartaz img { width: auto; height: auto; max-width: 100%; max-height: 70vh; margin: 0; }
.texto .evento-passado .evento-cartaz img { max-height: 30vh; }
/* fotos do evento: link no evento que já passou e a galeria (colunas que respeitam o formato de cada foto) */
.texto .evento-fotos { font-weight: 900; text-transform: uppercase; letter-spacing: 0.06em; font-size: calc(var(--corpo) * 0.85); margin-top: 1.5vh; }
.texto .evento-fotos a { text-decoration: none; }
.texto .evento-fotos a:hover { color: var(--destaque); }
.texto .galeria { columns: 3 240px; column-gap: 12px; margin: 4vh 0; }
.texto .galeria a { display: block; margin: 0 0 12px; break-inside: avoid; }
.texto .galeria img { width: 100%; height: auto; margin: 0; }
.texto .galeria a:hover img { outline: 3px solid var(--destaque); }
/* arquivo da agenda: um ano por linha, como o arquivo do blog */
.texto .agenda-arquivo { list-style: none; margin: 0 0 6vh; padding: 0; }
.texto .agenda-arquivo li { font-size: var(--corpo); margin-bottom: 1.2vh; }
.texto .agenda-arquivo a { font-weight: 900; }
.agenda-quantos { font-size: 0.85em; opacity: 0.75; margin-left: 0.6em; }

/* contador de visitas (GoatCounter): pixel invisível */
.contador { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

/* 16. CELULAR / RETRATO ----------------------------------- */
@media (orientation: portrait) {
    :root { --menu: clamp(11px, 3.2vmin, 15px); }
    .menu a, .arquivo > summary { padding: 2vmin 3vmin; }
    .botao-rss { padding: calc(2vmin - 2px) calc(3vmin - 2px); }
    .home-centro { width: 80vw; height: 80vw; }
    .assinatura { width: 35vmin; }
}
@media (max-width: 768px) {
    .topo { padding-left: 8vw; padding-right: 8vw; }

    /* menu recolhido */
    .menu-chave { display: block; position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
    .menu-botao {
        display: inline-flex; align-items: center; gap: 0.7em; cursor: pointer; user-select: none;
        font-weight: 900; font-size: var(--menu); letter-spacing: 0.1em; text-transform: uppercase;
        color: var(--creme); background: var(--marrom);
        padding: 2vmin 3vmin;
        transition: background-color 0.3s ease;
    }
    .menu-botao::before {
        content: ""; width: 1.15em; height: 0.85em;
        background:
            linear-gradient(currentColor 0 0) top / 100% 2px no-repeat,
            linear-gradient(currentColor 0 0) center / 100% 2px no-repeat,
            linear-gradient(currentColor 0 0) bottom / 100% 2px no-repeat;
    }
    .menu-chave:checked + .menu-botao { background: var(--destaque); color: #fff; }
    .menu-chave:focus-visible + .menu-botao { outline: 2px solid var(--destaque); outline-offset: 2px; }

    .menu-chave ~ .menu { display: none; }
    .menu-chave:checked ~ .menu {
        display: flex; flex-direction: column; gap: 0;
        position: absolute; top: 100%; left: 0; z-index: 300;
        width: min(300px, 84vw); padding: 6px 0;
        background: var(--marrom);
    }
    .menu-chave:checked ~ .menu a { background: transparent; padding: 15px 20px; font-size: 14px; }
    .menu-chave:checked ~ .menu a:hover { background: rgba(239, 69, 38, 0.25); }
    .menu-chave:checked ~ .menu a[aria-current="page"] { background: transparent; color: var(--destaque); }
    /* submenu dentro do painel do celular: vira um grupo que abre para baixo */
    .menu-chave:checked ~ .menu .submenu > summary { background: transparent; padding: 15px 20px; font-size: 14px; width: 100%; justify-content: space-between; }
    .menu-chave:checked ~ .menu .submenu.atual > summary { color: var(--destaque); }
    .menu-chave:checked ~ .menu .submenu-lista { position: static; transform: none; width: 100%; padding: 0 0 6px; background: rgba(0, 0, 0, 0.18); }
    .menu-chave:checked ~ .menu .submenu-lista a { padding: 13px 20px 13px 36px; font-size: 13px; }

    /* na home, o painel abre centralizado */
    .menu-home .menu-chave:checked ~ .menu { left: 50%; transform: translateX(-50%); }
    .pagina { padding: 6vh 8vw 4vh; }
    /* no celular a assinatura vai para o fim da página, sem cobrir o texto */
    .carta.com-arte { grid-template-columns: 1fr; gap: 0; }
    .carta-arte { width: 60%; max-width: 240px; margin: 0 auto 16px; }
    .tema-claro .assinatura { width: 30vmin; margin: 0 8vw calc(var(--moldura) + 4vh) auto; }
}
