/* ===== Barra de Acessibilidade (topo) ===== */
.accessibility-bar {
    width: 100%;
    background-color: var(--bg-card);
    border-bottom: 1px solid rgba(0,0,0,0.1);
    padding: 0.5rem 1rem;
}
[data-contrast="high"] .accessibility-bar { border-bottom: 1px solid #ffff00; }

.controls-container {
    display: flex; justify-content: center; align-items: center;
    max-width: 1200px; margin: 0 auto;
}

.visual-controls {
    display: flex;
    align-items: center;
    gap: 2px;
    background: var(--bg-primary);
    border: 1px solid var(--accent);
    border-radius: 8px;
    padding: 3px;
}
.visual-controls button {
    background: transparent; color: var(--text-primary);
    border: none; border-radius: 6px;
    width: 44px; height: 40px; font-weight: bold; cursor: pointer;
    font-size: 0.95rem;
    display: flex; align-items: center; justify-content: center;
    transition: background-color 0.15s, color 0.15s;
}
.visual-controls button + button { border-left: 1px solid rgba(128,128,128,0.25); }
.visual-controls button:hover { background: var(--accent); color: white; }
.visual-controls button[aria-pressed="true"] { background: var(--accent); color: white; }

/* ===== Empilhamento das barras do topo ===== */
.top-bars {
    position: fixed;
    top: 0; left: 0; width: 100%;
    z-index: 1000;
}

/* ===== Barra de idiomas (bandeiras) — logo abaixo da barra de acessibilidade ===== */
.lang-bar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    background: var(--bg-primary);
    border-bottom: 1px solid rgba(0,0,0,0.1);
    padding: 0.4rem 1rem;
}
[data-contrast="high"] .lang-bar { border-bottom: 1px solid #ffff00; }

.lang-flag {
    width: 52px; height: 52px;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    background: transparent;
    border: 2px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    gap: 2px;
}
.lang-flag svg { width: 26px; height: 18px; border-radius: 2px; box-shadow: 0 0 0 1px rgba(0,0,0,0.15); }
.lang-flag .flag-code {
    font-size: 0.6rem;
    font-weight: bold;
    color: var(--text-primary);
}
.lang-flag:hover { border-color: var(--accent); }
.lang-flag[aria-pressed="true"] { border-color: var(--accent); background: var(--bg-card); }

/* ===== Carrossel de fotos ===== */
.carousel {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    outline: none;
}
.carousel-track-wrap {
    overflow: hidden;
    border-radius: 8px;
    background: var(--bg-card);
}
.carousel-track {
    display: flex;
    transition: transform 0.35s ease;
}
.carousel-slide {
    position: relative;
    flex: 0 0 100%;
    height: 440px;
    overflow: hidden;
    background: var(--bg-primary);
}
.carousel-slide-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: blur(20px) brightness(0.65);
    transform: scale(1.15); /* evita ver a borda desfocada nas bordas do quadro */
}
.carousel-slide img {
    position: relative;
    z-index: 1;
    width: 100%; height: 100%;
    object-fit: contain; /* nunca corta a foto, seja retrato ou paisagem */
    display: block;
}
@media (max-width: 480px) {
    .carousel-slide { height: 340px; }
}
.carousel-btn {
    position: absolute;
    top: 50%; transform: translateY(-50%);
    background: rgba(10, 25, 47, 0.55);
    color: #ffffff;
    border: none;
    width: 44px; height: 44px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
}
.carousel-btn:hover { background: var(--accent); }
.carousel-prev { left: 0.5rem; }
.carousel-next { right: 0.5rem; }
.carousel-dots {
    display: flex; justify-content: center; gap: 0.5rem; margin-top: 1rem;
}
.carousel-dot {
    width: 12px; height: 12px; border-radius: 50%;
    border: 2px solid var(--accent);
    background: transparent;
    cursor: pointer;
    padding: 0;
}
.carousel-dot[aria-selected="true"] { background: var(--accent); }

/* ===== Bloco editável de história ===== */
.history-text {
    background-color: var(--bg-card);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}
.history-text p { margin-bottom: 1rem; }
.history-text p:last-child { margin-bottom: 0; }

/* ===== Exportação de publicações (estilo UbiAccess) ===== */
.export-bar {
    display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem;
    margin-bottom: 1.5rem;
}
.export-bar .copy-all-label { font-weight: bold; }
