/* Reset Básico */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden; 
}

body {
    font-family: 'Poppins', sans-serif;
    background: #fbf9f5;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #444;
}

/* =
   FUNDO DO SITE (O Blur atrás do livro)
= */
.background {
    position: fixed;
    inset: 0;
    background: url('../img/local-evento.jpeg') center/cover no-repeat;
    filter: blur(8px) brightness(0.9);
    transform: scale(1.05);
    z-index: -2; 
}

.background::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.45);
}

/* Contêiner que centraliza o livro */
.book-container {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    z-index: 1;
}

/* Tamanho do Livro */
#livro {
    width: 420px;
    height: 700px;
}

/* =
   SOLUÇÃO CRÍTICA PARA TRANSPARÊNCIA E BEGE
= */

.pagina {
    background-color: #fdfbf7 !important;
    opacity: 1 !important;

    /* Configurações de layout da página */
    padding: 40px;
    display: flex;
    align-items: flex-start; 
    justify-content: center;
    position: relative;
    border: 1px solid #e8e0d0;
    box-shadow: inset 0 0 100px rgba(139, 107, 45, 0.03);
}

.capa, .ultima {
    background: linear-gradient(180deg, #f8f4ea, #efe2c8) !important;
    color: #8b6b2d;
    opacity: 1 !important; 
    border: 1px solid #dcd1bb;
}

/* =
   CORREÇÃO DE CONTEÚDO DUPLO E FORMATAÇÃO
= */

/* Contêiner de conteúdo dentro de cada página */
cover-content,
section {
    width: 100%;
    text-align: center;
    display: block;
    opacity: 1;
}

/* --- TÍTULOS --- */
h2 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 42px;
    margin-bottom: 25px;
    margin-top: 0;
    color: #8b6b2d;

    text-align: center;
}

/* Parágrafos e Texto */
 p {
    font-size: 18px;
    line-height: 1.8;
    margin-bottom: 15px;

    text-align: justify;
    text-justify: inter-word;

    width: 100%;
}

/* --- IMAGENS--- */
img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 20px 0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* --- GALERIA GRID --- */
.galeria {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    width: 100%;
    margin-top: 20px;
}

.galeria img {
    aspect-ratio: 1/1;
    object-fit: cover;
    cursor: pointer;
    transition: transform 0.3s ease;
    margin: 0;
}

.galeria img:hover {
    transform: scale(1.04);
}

/* --- LOCALIZAÇÃO IFRAME --- */
iframe {
    width: 100%;
    height: 320px;
    border: none;
    border-radius: 12px;
    margin-bottom: 20px;
    display: block;
}

/* =
   BOTÕES E INTERAÇÃO
= */
button, .botao, .confirmar {
    display: inline-block;
    padding: 14px 30px;
    background: #b58b43;
    color: #fff;
    text-decoration: none;
    border: none;
    border-radius: 40px;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.3s ease;
    font-size: 16px;
    font-weight: 500;
}

button:hover, .botao:hover, .confirmar:hover {
    background: #8f6b30;
    transform: translateY(-2px);
}

/* Botão Flutuante de Música */
#musicButton {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    z-index: 999;
    font-size: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}
#contador {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

#contador > div {
    background: rgba(181, 139, 67, 0.1);
    border: 1px solid #b58b43;
    padding: 10px;
    border-radius: 8px;
    min-width: 70px;
    text-align: center;
}

#contador span {
    display: block;
    font-size: 24px;
    font-weight: 600;
    color: #8b6b2d;
}

#contador small {
    font-size: 12px;
    text-transform: uppercase;
    color: #8b6b2d;
    letter-spacing: 1px;
}
/* =
   ESTILO DA CAPA PERSONALIZADA
= */

.pagina.capa {
    padding: 0 !important;
    background: none !important;
    border: none !important;
    position: relative;
    overflow: hidden;
}

.capa .capa-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    margin: 0;
    box-shadow: none;
    border-radius: 0;
    display: block;
}

#abrirLivro {
    position: absolute;
    bottom: 50px; 
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    background: #b58b43; 
    color: #fff;
    border: none;
    padding: 15px 30px;
    border-radius: 40px;
    cursor: pointer;
}

#abrirLivro:hover {
    background: #8f6b30;
    transform: translateX(-50%) translateY(-2px);
}
/* Container do contador */
#contador {
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 20px;
    width: 100%;
}

/* Blocos individuais */
#contador > div {
    background: rgba(181, 139, 67, 0.1);
    border: 1px solid #b58b43;
    padding: 8px 5px;
    border-radius: 8px;
    flex: 1 1 60px;
    max-width: 80px;
    text-align: center;
}

/* Ajustes de fonte para não ficar grande demais no celular */
#contador span {
    display: block;
    font-size: 18px;
    font-weight: 600;
    color: #8b6b2d;
}

#contador small {
    font-size: 10px;
    text-transform: uppercase;
    color: #8b6b2d;
}

/* Media Query para telas muito pequenas */
@media (max-width: 480px) {
    #contador {
        gap: 5px;
    }
    #contador > div {
        flex: 1 1 50px;
        padding: 5px 2px;
    }
    #contador span {
        font-size: 16px;
    }
}

.textoluademel {
    font-size: 0.9em;
    color: #555;
    margin-bottom: 15px;
    margin: -25px auto 20px;
}
.pix{
    text-align: center; 
    padding: 10px;
     background-color:
      #fdf5e6;
       border-radius: 15px;
}
.textopix{
text-align: center;
padding: 10px; 
background-color:
#fdf5e6; 
border-radius: 15px;
max-width: 250px;
margin: -5px auto 20px;
}