/* Base Styles */
body {
    background-color: #0a0a0a;
    color: #f5f5f5;
    /* Fallback standard cursor */
    cursor: auto;
}

/* Custom Cursor logic */
@media (hover: hover) and (pointer: fine) {
    body {
        cursor: none;
    }
    a, button, input, select, textarea, .cursor-pointer, label {
        cursor: none !important;
    }
}

/* Custom Scrollbar Hiding */
.hide-scrollbar::-webkit-scrollbar {
    display: none;
}
.hide-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Marquee Animation */
@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-25%); }
}
.animate-marquee {
    animation: marquee 20s linear infinite;
}

/* Fade Utilities */
.mask-linear {
    mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
}

/* Hamburger Animation Classes */
.hamburger-open .hamburger-line:nth-child(1) {
    transform: rotate(45deg);
    top: 10px;
}
.hamburger-open .hamburger-line:nth-child(2) {
    opacity: 0;
}
.hamburger-open .hamburger-line:nth-child(3) {
    transform: rotate(-45deg);
    top: 10px;
}

/* Spin Animations for Loading */
@keyframes spin {
    to { transform: rotate(360deg); }
}
@keyframes spin-reverse {
    to { transform: rotate(-360deg); }
}
.animate-spin {
    animation: spin 1s linear infinite;
}
.animate-spin-reverse {
    animation: spin-reverse 1.5s linear infinite;
}

/* Smooth fade transition classes used by JS */
.fade-enter {
    opacity: 0;
    transform:
/* ============================================================= */
/* FIX IMMAGINI TAGLIATE NELLA GALLERY / LIGHTBOX (IL TUO CASO) */
/* ============================================================= */

/* Quando apri una pianta o immagine lunga nella lightbox ? la vedi intera */
#section-project-detail img,
.page-section img.w-full.h-full,
.grid-cols-1 img,
[class*="aspect-"] img {
    object-fit: contain !important;     /* ? questo risolve tutto */
    object-position: center !important;
    background: #000 !important;
}

/* Opzionale ma molto bello: sfondo nero e padding nella lightbox */
.page-section,
#section-project-detail,
.min-h-screen {
    background: #000 !important;
}

/* Cursore zoom per far capire che si può cliccare */
#section-project-detail img,
.page-section img {
    cursor: zoom-in;
}
/* FIX DEFINITIVO – IMMAGINI E PIANTE INTERE NELLA GALLERY / LIGHTBOX */
.aspect-\[21\/9\] img,
.aspect-\[4\/3\] img,
.aspect-\[16\/9\] img,
.aspect-\[3\/2\] img,
.aspect-\[1\/1\] img,
img.object-cover,
img.w-full.h-full,
#section-project-detail img,
.page-section img {
    object-fit: contain !important;
    object-position: center !important;
    background: #000 !important;
    max-height: 95vh !important;
    width: auto !important;
    height: auto !important;
}

/* Sfondo nero nella sezione progetto */
#section-project-detail,
.page-section.min-h-screen {
    background: #000 !important;
}