/* ========================================
   FLORIDA GYM - MOBILE RESPONSIVE FIX
   100% Mobile Ready | No Overflow | Perfect Layout
   ======================================== */

/* ========================================
   CRITICAL MOBILE FIXES
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
}

body {
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
    position: relative;
}

/* Fix tutti i container */
.container,
.container-hero,
section,
div {
    max-width: 100vw;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ========================================
   MOBILE HEADER - RESPONSIVE
   ======================================== */
@media (max-width: 768px) {
    .header {
        padding: 10px 0;
        width: 100%;
    }

    .header .container {
        padding: 0 16px;
        width: 100%;
    }

    .logo img {
        height: 40px;
        width: auto;
        max-width: 150px;
    }

    .hamburger {
        width: 40px;
        height: 40px;
        flex-shrink: 0;
    }

    /* Mobile Nav */
    .nav-mobile {
        top: 60px;
        width: 100%;
        left: 0;
        right: 0;
    }

    .nav-mobile a {
        padding: 14px 20px;
        font-size: 15px;
    }
}

/* ========================================
   MOBILE HERO - COMPLETAMENTE RESPONSIVE
   ======================================== */
@media (max-width: 768px) {
    .hero-modern {
        padding: 80px 16px 50px !important;
        min-height: auto !important;
        width: 100%;
    }

    .hero-content-wrapper {
        width: 100%;
        max-width: 100%;
        display: flex;
        flex-direction: column;
        gap: 32px;
    }

    .hero-main {
        width: 100%;
        max-width: 100%;
        order: 1;
    }

    /* Hero Label */
    .hero-label {
        padding: 8px 14px;
        font-size: 11px;
        width: fit-content;
        max-width: 100%;
    }

    /* Hero Headline */
    .hero-headline {
        font-size: 32px !important;
        line-height: 1.1;
        margin-bottom: 16px;
        word-wrap: break-word;
    }

    /* Hero Tagline */
    .hero-tagline {
        font-size: 16px !important;
        line-height: 1.6;
        margin-bottom: 24px;
    }

    /* Quick Stats - Stack Vertical */
    .hero-quick-stats {
        display: flex;
        flex-direction: column;
        gap: 12px;
        margin-bottom: 24px;
        width: 100%;
    }

    .quick-stat {
        display: flex;
        align-items: center;
        gap: 12px;
        width: 100%;
    }

    .quick-stat-icon {
        width: 50px;
        height: 50px;
        flex-shrink: 0;
        font-size: 22px;
    }

    .quick-stat-info {
        flex: 1;
    }

    .quick-stat-info strong {
        font-size: 24px;
        display: block;
        line-height: 1;
        margin-bottom: 4px;
    }

    .quick-stat-info span {
        font-size: 12px;
        display: block;
    }

    /* Hero Buttons - Full Width */
    .hero-cta-buttons {
        display: flex;
        flex-direction: column;
        gap: 12px;
        margin-bottom: 28px;
        width: 100%;
    }

    .btn-hero-primary,
    .btn-hero-secondary {
        width: 100% !important;
        padding: 16px 24px !important;
        font-size: 16px !important;
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 10px;
        text-align: center;
    }

    /* Social Proof */
    .hero-social-proof {
        width: 100%;
        max-width: 100%;
        padding: 18px 16px;
        display: flex;
        flex-direction: column;
        gap: 12px;
    }

    .proof-item {
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        font-size: 14px;
    }

    .proof-stars {
        display: flex;
        gap: 3px;
    }

    /* Hero Visual */
    .hero-visual {
        width: 100%;
        max-width: 100%;
        order: 2;
        margin-top: 0;
    }

    .hero-image-box {
        width: 100%;
        border-radius: 16px;
        position: relative;
    }

    .hero-img {
        width: 100%;
        height: auto;
    }

    /* Stat Cards - Smaller on Mobile */
    .stat-card {
        padding: 10px 12px;
        border-radius: 12px;
        gap: 10px;
        max-width: 160px;
    }

    .stat-1 {
        top: 12px;
        right: 12px;
    }

    .stat-2 {
        left: 12px;
        top: 45%;
    }

    .stat-3 {
        bottom: 12px;
        right: 12px;
    }

    .stat-icon {
        width: 40px;
        height: 40px;
        font-size: 18px;
        flex-shrink: 0;
    }

    .stat-info strong {
        font-size: 18px;
        line-height: 1;
    }

    .stat-info span {
        font-size: 11px;
        line-height: 1.2;
    }
}

/* ========================================
   MOBILE SECTIONS - RESPONSIVE
   ======================================== */
@media (max-width: 768px) {
    section {
        padding: 48px 16px !important;
        width: 100%;
    }

    .container {
        padding: 0 !important;
        width: 100%;
    }

    /* Section Headers */
    .section-header,
    .features-header {
        margin-bottom: 36px;
        text-align: center;
    }

    .features-label {
        padding: 6px 14px;
        font-size: 11px;
        margin-bottom: 12px;
    }

    .section-title,
    .features-header h2 {
        font-size: 28px !important;
        line-height: 1.2;
        margin-bottom: 10px;
    }

    .section-subtitle {
        font-size: 15px !important;
        line-height: 1.6;
    }

    /* Cards - Full Width */
    .feature-box,
    .service-card,
    .servizio-card {
        width: 100%;
        max-width: 100%;
        padding: 24px 20px;
        margin-bottom: 16px;
    }

    .feature-icon-wrapper,
    .service-icon,
    .servizio-icon {
        width: 60px;
        height: 60px;
        font-size: 28px;
        margin-bottom: 16px;
    }

    .feature-box h3,
    .service-card h3,
    .servizio-card h3 {
        font-size: 20px;
        margin-bottom: 8px;
    }

    .feature-box p,
    .service-card p,
    .servizio-card p {
        font-size: 14px;
        line-height: 1.6;
    }

    .service-cta,
    .servizio-cta {
        padding: 10px 18px;
        font-size: 14px;
    }

    /* Gallery - 1 Column */
    .gallery-grid {
        grid-template-columns: 1fr !important;
        gap: 14px;
    }

    .gallery-item {
        width: 100%;
        border-radius: 14px;
        aspect-ratio: 4/3;
    }

    /* Team Cards */
    .team-card {
        width: 100%;
        max-width: 100%;
        margin-bottom: 20px;
    }

    .team-image-wrapper {
        height: 260px;
    }

    .team-info {
        padding: 20px 18px;
    }

    .team-info h3 {
        font-size: 20px;
    }

    .team-role {
        font-size: 13px;
        margin-bottom: 12px;
    }

    .team-info p {
        font-size: 14px;
    }

    /* Social Proof Stats */
    .proof-stats {
        grid-template-columns: 1fr !important;
        gap: 16px;
    }

    .proof-stat {
        width: 100%;
        padding: 28px 20px;
    }

    .proof-icon {
        width: 60px;
        height: 60px;
        font-size: 28px;
        margin-bottom: 16px;
    }

    .proof-number {
        font-size: 44px;
        margin-bottom: 6px;
    }

    .proof-label {
        font-size: 15px;
        margin-bottom: 6px;
    }

    .proof-desc {
        font-size: 13px;
    }

    /* Footer */
    .footer {
        padding: 40px 16px 20px;
    }

    .footer-content {
        display: flex;
        flex-direction: column;
        gap: 24px;
    }

    .footer-logo img {
        height: 46px;
        margin: 0 auto 14px;
    }

    .footer-logo,
    .footer-links,
    .footer-contact {
        text-align: center;
    }

    .footer p,
    .footer a {
        font-size: 14px;
    }

    .footer-bottom {
        margin-top: 24px;
        padding-top: 16px;
        font-size: 12px;
    }
}

/* ========================================
   MOBILE WHATSAPP BUTTON
   ======================================== */
@media (max-width: 768px) {
    .whatsapp-fixed {
        bottom: 20px;
        right: 16px;
        width: 56px;
        height: 56px;
        font-size: 28px;
    }
}

/* ========================================
   MOBILE POPUP
   ======================================== */
@media (max-width: 768px) {
    .popup-card {
        width: 92%;
        max-width: 92%;
        padding: 32px 20px;
        margin: 0 16px;
    }

    .popup-card h3 {
        font-size: 22px;
        margin-bottom: 12px;
    }

    .popup-card p {
        font-size: 15px;
        margin-bottom: 20px;
    }

    .popup-card ul {
        margin-bottom: 24px;
    }

    .popup-card li {
        font-size: 14px;
        padding: 10px 0;
    }

    .popup-cta-btn,
    .popup-card a {
        width: 100%;
        padding: 14px 20px;
        font-size: 16px;
    }
}

/* ========================================
   EXTRA SMALL MOBILE (< 375px)
   ======================================== */
@media (max-width: 375px) {
    .hero-headline {
        font-size: 28px !important;
    }

    .hero-tagline {
        font-size: 15px !important;
    }

    .quick-stat-icon {
        width: 44px;
        height: 44px;
        font-size: 20px;
    }

    .quick-stat-info strong {
        font-size: 20px;
    }

    .btn-hero-primary,
    .btn-hero-secondary {
        padding: 14px 20px !important;
        font-size: 15px !important;
    }

    .stat-card {
        padding: 8px 10px;
        max-width: 140px;
    }

    .stat-icon {
        width: 36px;
        height: 36px;
        font-size: 16px;
    }

    .stat-info strong {
        font-size: 16px;
    }

    .stat-info span {
        font-size: 10px;
    }
}

/* ========================================
   LANDSCAPE MODE FIX
   ======================================== */
@media (max-width: 768px) and (orientation: landscape) {
    .hero-modern {
        min-height: auto !important;
        padding: 60px 16px 40px !important;
    }

    .hero-visual {
        max-height: 300px;
        overflow: hidden;
    }
}

/* ========================================
   DESKTOP (769px+)
   ======================================== */
@media (min-width: 769px) {
    .hero-modern {
        padding: 120px 40px 80px;
        min-height: 100vh;
    }

    .hero-content-wrapper {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 60px;
        max-width: 1200px;
        margin: 0 auto;
    }

    .hero-main {
        flex: 1;
        order: 1;
    }

    .hero-visual {
        flex: 1;
        order: 2;
    }

    .hero-headline {
        font-size: 58px !important;
        text-align: left;
    }

    .hero-tagline {
        font-size: 19px !important;
        text-align: left;
    }

    .hero-quick-stats {
        flex-direction: row;
        justify-content: flex-start;
    }

    .hero-cta-buttons {
        flex-direction: row;
        justify-content: flex-start;
    }

    .btn-hero-primary,
    .btn-hero-secondary {
        width: auto !important;
        min-width: 220px;
    }

    .hero-social-proof {
        flex-direction: row;
        justify-content: space-around;
        max-width: 100%;
    }

    section {
        padding: 80px 40px !important;
    }

    .container {
        max-width: 1200px;
        margin: 0 auto;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 24px;
    }

    .proof-stats {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    .hamburger {
        display: none;
    }

    .nav-mobile {
        display: none;
    }

    .nav-desktop {
        display: flex;
        gap: 32px;
        align-items: center;
    }

    .nav-desktop a {
        color: #1a1a1a;
        font-weight: 500;
        font-size: 15px;
        transition: 0.3s;
    }

    .nav-desktop a:hover {
        color: #FF9966;
    }
}

@media (min-width: 1024px) {
    .gallery-grid {
        grid-template-columns: repeat(4, 1fr) !important;
    }
}

/* ========================================
   PREVENT HORIZONTAL SCROLL
   ======================================== */
body,
html {
    overflow-x: hidden !important;
    max-width: 100vw !important;
}

* {
    max-width: 100%;
}

img,
video,
iframe {
    max-width: 100%;
    height: auto;
}

/* ========================================
   TEXT READABILITY
   ======================================== */
@media (max-width: 768px) {
    h1, h2, h3, h4, h5, h6,
    p, span, a, li {
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
    }
}

/* ========================================
   TOUCH OPTIMIZATION
   ======================================== */
@media (max-width: 768px) {
    button,
    a,
    .btn-hero-primary,
    .btn-hero-secondary,
    .service-cta {
        min-height: 44px;
        min-width: 44px;
    }

    /* Touch feedback */
    button:active,
    a:active {
        opacity: 0.8;
        transform: scale(0.98);
    }
}
