@media only screen 
  and (min-device-width: 1024px) 
  and (max-device-width: 1400px)
  and (-webkit-min-device-pixel-ratio: 2) {
    .header-container{
        width: 100%;
    }
  }



/* TABLET FINS A 1024px */

  @media screen and (max-width: 1024px) {
    /* HEADER */
     .grup-header{
        display: none !important;
    }

    .hero-header-mbl {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px;
        position: relative;
        z-index: 1001;
    }

    /* Forcem que el botó es vegi i estigui per sobre */
    .menu-toggle {
        display: block !important;
        background: transparent;
        border: none;
        color: black;
        font-size: 2rem;
        cursor: pointer;
        position: relative;
        z-index: 1100; /* Per sobre del menú desplegat */
    }

    /* El contenidor del menú */
    .hero-header-mbl .main-nav {
        display: none; /* Amagat per defecte */
        position: fixed;
        top: 0;
        right: -100%; 
        width: 100%; /* Millor 100% en mòbils petits */
        height: 100vh;
        background: white;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: right 0.4s ease;
        z-index: 1050;
    }

    /* Quan s'activa */
    .hero-header-mbl .main-nav.active {
        display: flex !important; /* El fem aparèixer */
        right: 0;
        gap: 50px;
    }

    .hero-header-mbl .main-nav ul {
        list-style: none;
        padding: 0;
        display: flex;
        flex-direction: column;
        gap: 25px;
        text-align: center;
    }

    .hero-header-mbl .main-nav ul li a {
        color: black;
        text-decoration: none;
        font-size: 1.8rem;
        font-family: 'Montserrat', sans-serif;
    }

    /* Idiomes al menú mòbil */
    .hero-header-mbl .lang-selector {
        display: flex;
        gap: 15px;
        margin-top: 10px;
    }

    .hero-header-mbl .lang-selector a {
        color: black;
        text-decoration: none;
        font-family: 'Montserrat', sans-serif;
        font-size: 1rem;
        opacity: 0.6;
    }

    .hero-header-mbl .lang-selector a.active {
        opacity: 1;
        font-weight: bold;
    }

    /* CONTINGUT RESTAURANTS */
    .restaurant-row{
        flex-direction: column;
    }

    .restaurant-row.reverse{
        flex-direction: column;
    }

    .restaurant-row.reverse .res-logo, .restaurant-row.reverse .rest-logo{
        align-self: flex-start;
        margin-left:0;
    }

    .restaurant-gallery {
        grid-template-columns: 1fr;
        width: 100%;
        
    }
    .restaurant-gallery img {
        width: 100%;
        height: 800px;
    }

    .restaurant-row {
        padding: 50px 25px;
    }

    .res-logo{
        max-width: 200px;
    }

    /* FOOTER */

    .footer-container{
        display: flex;
        flex-direction: column;
        gap: 20px;
        padding-top: 50px;
    }

    .footer-logo{
        margin-bottom: 0;
    }

    .footer-logo img{
        width: stretch;
    }

    .footer-social {
        position: relative;
        left: 0px;
        display: flex;
        gap: 15px;
        
    }

    .footer-bottom {
        flex-direction: column-reverse;
        gap: 40px;
    }

    .footer-group-logos{
        display: none;
    }

    .mobile-logos-section-footer {
        display: block !important;
        background-color: white;
        padding: 40px 20px; /* Afegeix padding per donar aire */
        width: 100%;
        box-sizing: border-box;
        opacity: 1 !important; /* Forcem visibilitat */
        transform: none !important; /* Anul·lem el desplaçament de l'animació */
    }

    .logos-grid-mbl {
        display: grid !important;
        grid-template-columns: repeat(4, 1fr) !important; 
        gap: 30px;
        align-items: center;
        justify-items: center;
        padding: 5%;
    }

    .logos-grid-mbl .logo-item {
        opacity: 1 !important; 
        transform: none !important;
        padding: 0;
    }

        .footer-logo img{
        width: 228px;
    }

    .logos-grid-mbl img {
        max-width: 100%;
        height: auto;
        filter: none !important; 
    }


  }



/* DISPOSITIUS TELÈFONS PETITS */
@media only screen 
  and (min-device-width: 320px) 
  and (max-device-width: 480px)
  and (-webkit-min-device-pixel-ratio: 2)
  and (orientation: portrait) {

    /* HEADER */
     .grup-header{
        display: none !important;
    }

    .hero-header-mbl {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px;
        position: relative;
        z-index: 1001;
    }

    /* Forcem que el botó es vegi i estigui per sobre */
    .menu-toggle {
        display: block !important;
        background: transparent;
        border: none;
        color: black;
        font-size: 2rem;
        cursor: pointer;
        position: relative;
        z-index: 1100; /* Per sobre del menú desplegat */
    }

    /* El contenidor del menú */
    .hero-header-mbl .main-nav {
        display: none; /* Amagat per defecte */
        position: fixed;
        top: 0;
        right: -100%; 
        width: 100%; /* Millor 100% en mòbils petits */
        height: 100vh;
        background: white;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: right 0.4s ease;
        z-index: 1050;
    }

    /* Quan s'activa */
    .hero-header-mbl .main-nav.active {
        display: flex !important; /* El fem aparèixer */
        right: 0;
        gap: 50px;
    }

    .hero-header-mbl .main-nav ul {
        list-style: none;
        padding: 0;
        display: flex;
        flex-direction: column;
        gap: 25px;
        text-align: center;
    }

    .hero-header-mbl .main-nav ul li a {
        color: black;
        text-decoration: none;
        font-size: 1.8rem;
        font-family: 'Montserrat', sans-serif;
    }

    /* Idiomes al menú mòbil */
    .hero-header-mbl .lang-selector {
        display: flex;
        gap: 15px;
        margin-top: 10px;
    }

    .hero-header-mbl .lang-selector a {
        color: black;
        text-decoration: none;
        font-family: 'Montserrat', sans-serif;
        font-size: 1rem;
        opacity: 0.6;
    }

    .hero-header-mbl .lang-selector a.active {
        opacity: 1;
        font-weight: bold;
    }

   
    
    .restaurant-row{
        flex-direction: column;
    }

    .restaurant-row.reverse{
        flex-direction: column;
    }

    .restaurant-row.reverse .res-logo, .restaurant-row.reverse .rest-logo{
        align-self: flex-start;
        margin-left:0;
    }

    .restaurant-gallery {
        grid-template-columns: 1fr;
    }

    .restaurant-row {
        padding: 25px 15px;
    }

     .res-logo{
        max-width: 150px;
    }

    .restaurant-gallery img {
        height: 600px;
    }

    /* FOOTER */

    .footer-container{
        display: flex;
        flex-direction: column;
        gap: 20px;
        padding-top: 50px;
    }

    .footer-logo{
        margin-bottom: 0;
    }

    .footer-logo img{
        width: stretch;
    }

    .footer-social {
        position: relative;
        left: 0px;
        display: flex;
        gap: 15px;
        
    }

    .footer-nav {
        flex-direction: column;
    }

    .footer-bottom {
        flex-direction: column-reverse;
        gap: 40px;
    }

    .footer-group-logos{
        display: none;
    }

    .mobile-logos-section-footer {
        display: block !important;
        background-color: white;
        padding: 40px 20px; /* Afegeix padding per donar aire */
        width: 100%;
        box-sizing: border-box;
        opacity: 1 !important; /* Forcem visibilitat */
        transform: none !important; /* Anul·lem el desplaçament de l'animació */
    }

    .logos-grid-mbl {
        display: grid !important;
        grid-template-columns: repeat(4, 1fr) !important; 
        gap: 30px;
        align-items: center;
        justify-items: center;
    }

    .logos-grid-mbl .logo-item {
        opacity: 1 !important; 
        transform: none !important;
        padding: 0;
    }

    .logos-grid-mbl img {
        max-width: 100%;
        height: auto;
        filter: none !important; 
    }
}