
.ho-brochure{display:inline-block}

.ho-brochure-modal{
    position:fixed;inset:0;z-index:999999;display:none;
    background:#743921;color:#D4CBC2
}
.ho-brochure-modal.is-open{display:flex;flex-direction:column}

.ho-brochure-modal__topbar{
    position:relative;z-index:10;
    display:flex;align-items:center;justify-content:space-between;gap:20px;
    padding:18px 24px;
    border-bottom:1px solid rgba(240,239,237,.16)
}
.ho-brochure-modal__title{
    margin:0;
    font-size:14px;font-weight:500;letter-spacing:.04em;text-transform:uppercase
}
.ho-brochure-modal__actions{display:flex;align-items:center;gap:12px}

.ho-brochure-modal__download,
.ho-brochure-modal__close{
    display:inline-flex;align-items:center;justify-content:center;
    min-height:42px;padding:10px 16px;
    border:1px solid rgba(240,239,237,.6);
    border-radius:100px;
    background:transparent;color:#F0EFED;
    text-decoration:none;cursor:pointer
}
.ho-brochure-modal__close{
    width:42px;padding:0;font-size:24px
}

.ho-brochure-modal__stage{
    position:relative;
    flex:1 1 auto;min-height:0;
    display:flex;align-items:center;justify-content:center;
    padding: 12px 24px 8px;
    overflow:hidden
}
.ho-brochure-modal__book-wrap{
    position:relative;
    width: 100%;
    max-width: 1500px;
    height:100%;
    display:flex;align-items:center;justify-content:center;
    background:#743921
}
.ho-brochure-modal__book{width:100%;height:100%}
.ho-brochure-modal__page{background:#fff;overflow:hidden}
.ho-brochure-modal__page canvas{
    display:block;width:100%;height:100%;
    object-fit:contain!important;background:#fff
}

.ho-brochure-modal__loader{
    position:absolute;inset:0;z-index:8;
    display:flex;flex-direction:column;align-items:center;justify-content:center;
    gap:18px;padding:30px;text-align:center;
    background:#743921
}
.ho-brochure-modal__loader.is-hidden{display:none}

.ho-brochure-modal__loader-cover{
    position:relative;
    width:min(360px,70vw);
    max-height:68vh;
    aspect-ratio:.707 / 1;
    overflow:hidden;
    background:#5F2F1C;
    box-shadow:0 20px 60px rgba(0,0,0,.35)
}
.ho-brochure-modal__loader-cover canvas{
    display:block;width:100%;height:100%;
    object-fit:contain;background:#fff
}
.ho-brochure-modal__loader-status{
    display:flex;align-items:center;justify-content:center;gap:10px;
    color:rgba(240,239,237,.82);
    font-size:13px;letter-spacing:.03em
}
.ho-brochure-modal__spinner{
    width:14px;height:14px;
    border:1.5px solid rgba(240,239,237,.25);
    border-top-color:#F0EFED;border-radius:50%;
    animation:hoBrochureSpin .8s linear infinite
}
@keyframes hoBrochureSpin{to{transform:rotate(360deg)}}

.ho-brochure-modal__nav{
    position:absolute;
    top:50%;
    z-index:6;
    width:46px;
    height:46px;
    transform:translateY(-50%);
    border:1px solid rgba(240,239,237,.5);
    border-radius:50%;
    background:rgba(116,57,33,.78);
    color:#F0EFED;
    font-size:26px;
    cursor:pointer;
}

.ho-brochure-modal__nav--prev{left:18px}
.ho-brochure-modal__nav--next{right:18px}

.ho-brochure-modal__footer{
    display:flex;justify-content:center;align-items:center;
    min-height:52px;
    padding:8px 20px 14px;
    font-size:13px;
    color:rgba(240,239,237,.72)
}
body.ho-brochure-open{overflow:hidden!important}

@media(max-width:767px){
    .ho-brochure-modal__topbar{padding:12px 14px}
    .ho-brochure-modal__title{
        max-width:42vw;
        white-space:nowrap;overflow:hidden;text-overflow:ellipsis
    }
    .ho-brochure-modal__download{padding:9px 12px;font-size:10px}
    .ho-brochure-modal__close{width:38px;min-height:38px}
    .ho-brochure-modal__stage{padding:10px 6px 6px}
    .ho-brochure-modal__nav{display:none}
}


/* =========================================================
   V1.0.4 — ESTABILIZAÇÃO DA ABERTURA
   O livro só fica visível depois do cálculo final do PageFlip.
   ========================================================= */

.ho-brochure-modal__book {
    opacity: 0;
}

.ho-brochure-modal.is-ready .ho-brochure-modal__book {
    opacity: 1;
    transition: opacity .18s ease;
}

/* Link auxiliar opcional usado nos tabs/raw HTML.
   O visual pode continuar a ser controlado pelas classes do site. */
.brochure-section-link {
    cursor: pointer;
}
