/* Novizki Site Manager - Homepage Full-Screen Styles */

/* Full-screen homepage container */
.nvz-fullscreen {
    width: 100vw;
    height: 100svh;
    min-height: 100svh;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1;
    margin: 0;
    padding: 0;
    overflow: hidden;
    background: #000;
}

/* Admin bar adjustment */
.admin-bar .nvz-fullscreen {
    height: calc(100svh - 32px);
}

@media (max-width: 782px) {
    .admin-bar .nvz-fullscreen {
        height: calc(100svh - 46px);
    }
}

/* Desktop and Mobile specific containers */
.nvz-fullscreen .novizki-homepage-container.desktop {
    display: none;
    width: 100%;
    height: 100%;
}

.nvz-fullscreen .novizki-homepage-container.mobile {
    display: none;
    width: 100%;
    height: 100%;
}

/* Show appropriate container based on screen size */
@media (min-width: 769px) {
    .nvz-fullscreen .novizki-homepage-container.desktop {
        display: block;
    }
}

@media (max-width: 768px) {
    .nvz-fullscreen .novizki-homepage-container.mobile {
        display: block;
    }
}

/* Image styling within containers */
.nvz-fullscreen .novizki-homepage-container img {
    max-width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
}

/* Flexbox layout styles */
.nvz-fullscreen .novizki-homepage-container.flex {
    display: flex;
    width: 100%;
    height: 100%;
}

.nvz-fullscreen .novizki-homepage-container.flex img {
    flex-shrink: 0;
}

/* Absolute positioning styles */
.nvz-fullscreen .novizki-homepage-container.absolute {
    position: relative;
    width: 100%;
    height: 100%;
}

.nvz-fullscreen .novizki-homepage-container.absolute img {
    position: absolute;
}

/* Responsive image sizing */
.nvz-fullscreen .novizki-homepage-container img {
    transition: all 0.3s ease;
}

/* Ensure images fill viewport without overflow */
.nvz-fullscreen .novizki-homepage-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Hamburger menu positioning */
.nvz-fullscreen+.hamburger-menu,
body.home .hamburger-menu {
    position: fixed !important;
    top: 20px !important;
    right: 20px !important;
    z-index: 9999 !important;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 4px;
    padding: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Image effects and transitions */
.nvz-fullscreen .novizki-homepage-container img {
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.nvz-fullscreen .novizki-homepage-container img:hover {
    transform: scale(1.05);
}

/* Loading states */
.nvz-fullscreen .novizki-homepage-container.loading {
    opacity: 0.7;
}

.nvz-fullscreen .novizki-homepage-container.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #0073aa;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Error states */
.nvz-fullscreen .novizki-homepage-container.error {
    background: #f8d7da;
    color: #721c24;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
}

/* Accessibility improvements */
.nvz-fullscreen .novizki-homepage-container img[alt] {
    position: relative;
}

.nvz-fullscreen .novizki-homepage-container img[alt]:hover::after {
    content: attr(alt);
    position: absolute;
    bottom: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 10;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .nvz-fullscreen {
        border: 2px solid #000;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .nvz-fullscreen .novizki-homepage-container img {
        transition: none;
    }

    .nvz-fullscreen .novizki-homepage-container img:hover {
        transform: none;
    }
}

/* Print styles */
@media print {
    .nvz-fullscreen {
        display: none !important;
    }
}

/* Focus styles for accessibility */
.nvz-fullscreen:focus-within {
    outline: 2px solid #0073aa;
    outline-offset: 2px;
}

/* Ensure proper stacking context */
.nvz-fullscreen {
    isolation: isolate;
}

/* Support for different image aspect ratios */
.nvz-fullscreen .novizki-homepage-container img.portrait {
    object-fit: cover;
    object-position: center;
}

.nvz-fullscreen .novizki-homepage-container img.landscape {
    object-fit: cover;
    object-position: center;
}

.nvz-fullscreen .novizki-homepage-container img.square {
    object-fit: cover;
    object-position: center;
}

/* Mobile-specific optimizations */
@media (max-width: 768px) {
    .nvz-fullscreen {
        height: 100dvh;
    }
}

/* Landscape orientation adjustments */
@media (orientation: landscape) and (max-height: 500px) {
    .nvz-fullscreen {
        height: 100vh;
    }
}

/* Portrait orientation adjustments */
@media (orientation: portrait) and (max-width: 768px) {
    .nvz-fullscreen {
        height: 100dvh;
    }
}