/*
Theme Name: baloogroot
Template: twentytwentyfive
*/

html, body { 
    overflow-x: hidden; 
    width: 100%; 
    margin: 0; 
}

:where(.wp-site-blocks) > :first-child { margin-top: 0 !important; }
:root :where(.is-layout-constrained) > *:nth-child(2) { margin-block-start: 0; }

h1.wp-block-post-title { display: none !important; }

.custom-carousel-wrapper {
    position: relative;
    width: 100vw;
    height: 100vh;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    margin-top: 0 !important;
    overflow: hidden;
    background: #000;
    touch-action: pan-y;
    user-select: none;
}

#carousel-track {
    display: flex !important;
    width: 100%;
    cursor: grab;
}

.carousel-item {
    flex: 0 0 100vw !important;
    width: 100vw !important;
    height: 100vh;
}

.carousel-item img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    pointer-events: none;
}

figure.wp-block-image.logo {
    position: absolute !important;
    bottom: 60px;
    left: 50% !important;
    transform: translateX(-50%) !important;
    z-index: 1000;
    margin: 0;
    width: 100vw;
    pointer-events: none;
}

figure.wp-block-image.logo img {
    width: 65vw;
    height: auto !important;
}

.nav-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1010 !important;
    background: rgba(0, 0, 0, 0.5) !important;
    color: #fff !important;
    border: none;
    padding: 20px;
    cursor: pointer;
    font-size: 30px;
}

.prev { left: 0; }
.next { right: 0; }

@media (max-width: 768px) {
    .custom-carousel-wrapper,
    .carousel-item {
        height: 80vh !important; 
    }

    figure.wp-block-image.logo {
        bottom: 30px;
    }

    figure.wp-block-image.logo img {
        width: 90vw; 
    }

    .nav-arrow {
        padding: 1rem;
        font-size: 1.5rem;
    }
}

/* Skrytí zdroje galerie */
body:not(.block-editor-page) .carousel-source {
    display: none !important;
}