/* Customização cadFiber - Logo SVG no header e sidebar */

/* Esconder qualquer SVG padrão do tema no header */
.logo-icon svg {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    width: 0 !important;
    height: 0 !important;
}

/* Logo no header (top-header) - APENAS quando sidebar estiver FECHADA */
/* Quando sidebar está VISÍVEL (.toggled), esconder logo do header */
.page-wrapper.toggled #cadfiber-logo-link {
    display: none !important;
}

/* Quando sidebar está ESCONDIDA (sem .toggled), mostrar logo do header */
.page-wrapper:not(.toggled) #cadfiber-logo-link {
    display: flex !important;
    align-items: center !important;
    position: relative !important;
    text-decoration: none !important;
}

#cadfiber-logo-link #cadfiber-logo-big {
    display: block !important;
}

#cadfiber-logo-link #cadfiber-logo-big-img {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: 40px !important;
    width: auto !important;
    position: relative !important;
    z-index: 1 !important;
}

/* Em telas pequenas, mostrar apenas .small */
@media (max-width: 767px) {
    #cadfiber-logo-link #cadfiber-logo-small {
        display: flex !important;
    }
    #cadfiber-logo-link #cadfiber-logo-big {
        display: none !important;
    }
}

/* Em telas médias e grandes, mostrar apenas .big */
@media (min-width: 768px) {
    #cadfiber-logo-link #cadfiber-logo-small {
        display: none !important;
    }
    #cadfiber-logo-link #cadfiber-logo-big {
        display: flex !important;
    }
}

/* Logo na sidebar - SUBSTITUIR ÍCONE AZUL DO LIVRO */
#cadfiber-sidebar-logo-link {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    text-decoration: none !important;
}

#cadfiber-sidebar-logo-link svg {
    display: none !important; /* Esconder qualquer SVG padrão */
}

#cadfiber-sidebar-logo {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: 40px !important;
    width: auto !important;
    position: relative !important;
    z-index: 1 !important;
}

/* Esconder SVG padrão do tema na sidebar */
.sidebar-brand > a > svg {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    width: 0 !important;
    height: 0 !important;
}

/* Garantir que apenas uma imagem apareça por vez */
.top-header .header-bar .logo-icon .small {
    display: none !important;
}

.top-header .header-bar .logo-icon .small img {
    height: 32px !important;
    width: auto !important;
    display: block !important;
}

.top-header .header-bar .logo-icon .big {
    display: block !important;
}

.top-header .header-bar .logo-icon .big img {
    height: 40px !important;
    width: auto !important;
    display: block !important;
}

/* Em telas pequenas (mobile), mostrar apenas .small */
@media (max-width: 767px) {
    .top-header .header-bar .logo-icon {
        display: flex !important;
        align-items: center !important;
    }
    .top-header .header-bar .logo-icon .small {
        display: block !important;
    }
    .top-header .header-bar .logo-icon .big {
        display: none !important;
    }
    .top-header .header-bar .logo-icon svg,
    .top-header .header-bar .logo-icon .small svg,
    .top-header .header-bar .logo-icon .big svg {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        width: 0 !important;
        height: 0 !important;
    }
}

/* Em telas médias, mostrar apenas .big */
@media (min-width: 768px) and (max-width: 1024px) {
    .top-header .header-bar .logo-icon {
        display: flex !important;
        align-items: center !important;
    }
    .top-header .header-bar .logo-icon .small {
        display: none !important;
    }
    .top-header .header-bar .logo-icon .big {
        display: block !important;
    }
    .top-header .header-bar .logo-icon svg,
    .top-header .header-bar .logo-icon .small svg,
    .top-header .header-bar .logo-icon .big svg {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        width: 0 !important;
        height: 0 !important;
    }
}

/* Garantir que o logo apareça mesmo em telas grandes (acima de 1024px) */
@media (min-width: 1025px) {
    .top-header .header-bar .logo-icon {
        display: flex !important;
        align-items: center !important;
    }
    .top-header .header-bar .logo-icon .big {
        display: block !important;
    }
    .top-header .header-bar .logo-icon .small {
        display: none !important;
    }
    .top-header .header-bar .logo-icon svg,
    .top-header .header-bar .logo-icon .small svg,
    .top-header .header-bar .logo-icon .big svg {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        width: 0 !important;
        height: 0 !important;
    }
}

