/* ================================================
   CONTACT.CSS - Contact Page with Responsive Images
   ================================================ */

/* Basic Reset (inherited from motherpages.css) */
body {
    overflow: hidden;
}

/* ================================================
   CONTACT CONTAINER
   ================================================ */
.contact-container {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    bottom: 80px;
    display: flex;
    align-items: center;
}

/* Background image */
.contact-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 1;
}

/* Contact text overlay - LEFT for desktop/landscape */
.contact-text {
    position: relative;
    z-index: 2;
    padding: 40px;
    max-width: 600px;
    margin-left: 80px;
    font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
    color: #666;
}

.contact-name {
    font-size: 24px;
    font-weight: 600;
    margin: 0 0 8px 0;
    color: #666;
}

.contact-location {
    font-size: 18px;
    margin: 0 0 20px 0;
    color: #666;
}

.contact-divider {
    width: 200px;
    height: 1px;
    background: #666;
    border: none;
    margin: 0 0 20px 0;
}

.contact-info {
    font-size: 16px;
    line-height: 1.6;
    margin: 0 0 12px 0;
    color: #666;
}

.contact-email {
    font-size: 16px;
    margin: 0;
    color: #666;
}

.contact-email a {
    color: #666;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.contact-email a:hover {
    color: #333;
}

/* Footer social icons - DESKTOP (in footer) */
.footer-social {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 24px;
}

.footer-social a {
    color: #aaa;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
}

.footer-social a:hover {
    color: #666;
}

.footer-social svg {
    width: 24px;
    height: 24px;
}

/* Mobile social icons - Hidden on desktop */
.footer-social-mobile {
    display: none;
}

/* Hamburger menu (hidden on desktop) */
.hamburger {
    display: none;
}

/* ================================================
   MOBILE VERSION
   max-width: 940px OR max-height: 600px
   ================================================ */
@media only screen and (max-width: 940px), 
       only screen and (max-height: 600px) {
    
    body {
        overflow: hidden;
    }
    
    /* Hide logo */
    .logo-holder {
        display: none;
    }
    
    /* Hide footer and desktop social */
    footer {
        display: none;
    }
    
    .footer-social {
        display: none !important;
    }

    /* Show mobile social on image (default: landscape left position) */
    .footer-social-mobile {
        display: flex;
        position: fixed;
        bottom: 30px;
        left: 68px;
        transform: none;
        z-index: 1000;
        gap: 24px;
    }

    .footer-social-mobile a {
        color: #fff;
        filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
        display: flex;
        align-items: center;
    }
    
    .footer-social-mobile svg {
        width: 24px;
        height: 24px;
    }
    
    /* Show hamburger */
    .hamburger {
        display: flex;
        flex-direction: column;
        /*gap: 6px; rimosso per aggiustare su ios 12 dove non è supportato*/
        background: none;
        border: none;
        cursor: pointer;
        padding: 8px;
        position: fixed;
        top: 15px;
        right: 20px;
        z-index: 1002;
    }
    
    .hamburger span {
        margin: 3px 0;  /* aggiunto per ios12 */
        width: 35px;
        height: 5px;
        background: #666;
        transition: all 0.2s ease;
    }
    
    .hamburger:hover span {
        background: #666;
    }
    
    /* Hamburger animation when open */
    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(8px, 8px);
    }
    
    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }
    
    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
    }
    
    /* Navigation overlay */
    header {
        background: transparent;
        padding: 0;
    }
    
    .header-inner {
        display: block;
    }
    
    /* Navigation overlay fullscreen */
.nav-holder {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 400px;
    max-height: 80vh;
    overflow-y: auto;
    background: rgba(255, 255, 255, 0.95);
    /* backdrop-filter rimosso per iOS 12 */
    display: block;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
    padding: 40px 20px;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.nav-holder.active {
    opacity: 1;
    pointer-events: all;
}

.nav-holder nav ul {
    text-align: center;
    width: 100%;
}

.nav-holder nav ul li {
    display: block;
    margin-bottom: 20px;
}

.nav-holder nav ul li:last-child {
    margin-bottom: 0;
}

.nav-holder nav ul li a {
    font-size: 16px;
}

.nav-holder nav ul li a:hover {
    color: #000;
}
    
    /* Fullscreen contact */
    .contact-container {
        top: 0;
        bottom: 0;
    }
    
    /* Default mobile (landscape) styles */
    .contact-text {
        margin-left: 40px;
        padding: 30px;
        max-width: 500px;
    }
    
    .contact-name {
        font-size: 20px;
    }
    
    .contact-location {
        font-size: 16px;
    }
    
    .contact-info,
    .contact-email {
        font-size: 14px;
    }
    
    .contact-divider {
        width: 150px;
    }
}

/* ================================================
   MOBILE PORTRAIT - Separate media query
   ================================================ */
@media only screen and (max-width: 940px) and (orientation: portrait),
       only screen and (max-height: 600px) and (orientation: portrait) {
    
    /* Text centered in portrait */
    .contact-text {
        position: absolute;
        top: 65%;
        left: 50%;
        transform: translate(-50%, -50%);
        text-align: center;
        margin: 0;
        padding: 40px 20px;
        max-width: 90%;
    }
    
    .contact-divider {
        margin: 20px auto;
    }
    
    /* Social centered in portrait */
    .footer-social-mobile {
        left: 50%;
        transform: translateX(-50%);
    }
}