@font-face {
    font-family: 'CornDemo-Regular';
    src: url('Comfortaa-VariableFont_wght.ttf');
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'CornDemo-Regular', sans-serif;
    color: white;
    background: url('immagini/sfondohome.jpg') no-repeat center center/cover;
    min-height: 100vh;
    overflow-x: hidden;
}

/* ============================= */
/* CAROUSEL */
/* ============================= */

.carousel {
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    padding: 15px 0 5px 0; /* meno spazio sotto */
}

.carousel-track {
    display: inline-block;
    animation: scroll 50s linear infinite;
}

.carousel-track span {
    margin: 0 30px;
    font-size: 1.05rem;
    letter-spacing: 2px;
    font-weight: bold;   /* GRASSETTO */
    opacity: 0.9;
}

@keyframes scroll {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

/* ============================= */
/* HERO */
/* ============================= */

.hero {
    text-align: center;
    padding: 35px 20px 20px; /* meno distanza dal carousel */
}

.hero h1 {
    font-size: clamp(2.2rem, 3.5vw, 3rem);
    margin-bottom: 10px;
}

.hero h2 {
    font-size: clamp(1.2rem, 1.8vw, 1.6rem);
    margin-bottom: 12px;
}

.hero p {
    font-size: clamp(0.95rem, 1.2vw, 1.1rem);
    margin-bottom: 45px; /* meno spazio prima dei bottoni */
}

/* ============================= */
/* BOTTONI OTTIMIZZATI FULLSCREEN */
/* ============================= */

.buttons-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    max-width: 1500px;
    margin: 0 auto;
    padding: 0 40px 30px 40px; /* meno spazio sotto */
}

.buttons-container a {
    display: flex;
    justify-content: center;
    align-items: center;
}

.buttons-container img {
    width: 100%;
    max-width: 280px; /* leggermente ridotti per stare tutti nella viewport */
    aspect-ratio: 1 / 1;
}

/* Hover elegante che segue il PNG */
.buttons-container img:hover {
    transform: scale(1.15);
    filter: drop-shadow(0 0 25px rgba(255,255,255,0.9));
}

/* ============================= */
/* LINKEDIN DENTRO HERO */
/* ============================= */

.hero {
    position: relative; /* necessario per ancorare il linkedin */
}

.hero-linkedin {
    position: absolute;
    bottom: 20px;
    right: 30px;
}

.hero-linkedin img {
    width: 45px;
    height: 45px;
    filter: brightness(0) invert(1); /* rende bianco */
    transition: filter 0.3s ease, transform 0.3s ease;
    cursor: pointer;
}

.hero-linkedin img:hover {
    filter: invert(66%) sepia(97%) saturate(405%) hue-rotate(166deg) brightness(94%) contrast(95%);
    transform: scale(1.1);
}

/* ============================= */
/* FOOTER */
/* ============================= */

footer {
    background: white;
    color: #13BFED;
    padding: 30px 40px 50px 40px; /* meno spazio sopra, più equilibrio sotto */
    position: relative;
}

/* Linea azzurra superiore */
footer::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: #13BFED;
}

/* Logo + titolo cliccabili */
.footer-logo {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 18px;
    margin: 40px 0 35px 0;
    text-decoration: none;
    flex-wrap: wrap;
}

.footer-logo img {
    height: 70px;
}

.footer-logo span {
    font-size: 1.9rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: #13BFED; /* stesso colore del resto */
}

.footer-logo:hover {
    opacity: 0.85;
}

/* Info tutte su una riga desktop */
.footer-info {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 40px;
    max-width: 1500px;
    margin: 0 auto;
    flex-wrap: nowrap;
}

/* Blocchi */
.footer-block {
    display: flex;
    flex-direction: column;
    gap: 10px;
    text-align: left;
}

/* Categorie */
.footer-block strong {
    font-weight: 700;
    font-size: 1.15rem;
    margin-bottom: 5px;
}

/* Info */
.footer-block span,
.footer-block a {
    font-size: 1.02rem;
    text-decoration: none;
    color: #13BFED;
    transition: opacity 0.3s ease;
}

.footer-block a:hover {
    opacity: 0.7;
}

/* ============================= */
/* FOOTER LEGAL LINKS */
/* ============================= */

.footer-legal {
    margin-top: 45px;
    text-align: center;
    font-size: 0.95rem;
}

.footer-legal a {
    color: #13BFED;
    text-decoration: none;
    font-weight: 600;
    transition: opacity 0.3s ease;
}

.footer-legal a:hover {
    opacity: 0.7;
}

.footer-legal span {
    margin: 0 12px;
}

/* ============================= */
/* PAGINA PRIVACY & COOKIE */
/* ============================= */

.legal-page {
    max-width: 900px;
    margin: 80px auto;
    padding: 50px;
    background: rgba(0,0,0,0.75);
    border-radius: 8px;
}

.legal-page h1 {
    margin-bottom: 30px;
    font-size: 2rem;
}

.legal-page h2 {
    margin-top: 30px;
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.legal-page h3 {
    margin-top: 20px;
    margin-bottom: 8px;
    font-size: 1rem;
}

.legal-page p {
    line-height: 1.7;
    font-size: 0.95rem;
}

.legal-page hr {
    margin: 30px 0;
    border: 0;
    height: 1px;
    background: rgba(255,255,255,0.3);
}

/* ============================= */
/* PAGINE SERVIZI */
/* ============================= */

.service-page {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 60px 20px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.service-content {
    max-width: 900px;
    background: rgba(0, 0, 0, 0.75);
    padding: 60px;
    border-radius: 8px;
    text-align: center;
}

.service-content h1 {
    font-size: clamp(2rem, 3vw, 3rem);
    margin-bottom: 20px;
}

.service-content h2 {
    font-size: clamp(1.2rem, 2vw, 1.6rem);
    margin-bottom: 25px;
    font-weight: normal;
    opacity: 0.9;
}

.service-content p {
    font-size: 1rem;
    line-height: 1.7;
}

/* Responsive */
@media (max-width: 768px) {
    .service-content {
        padding: 40px 25px;
    }
}

.service-content h3 {
    margin-top: 35px;
    margin-bottom: 15px;
    font-size: 1.1rem;
    font-weight: bold;
}

.service-content p {
    margin-bottom: 15px;
    line-height: 1.7;
}

.service-content ul {
    list-style: none;
    padding: 0;
    margin: 15px 0 25px 0;
}

.service-content ul li {
    margin-bottom: 8px;
    padding-left: 18px;
    position: relative;
}

.service-content ul li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: #13BFED;
}


/* ============================= */
/* PAGINA PARTNER */
/* ============================= */

.partner-page {
    min-height: 100vh;
    padding: 100px 40px;
    text-align: center;

    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
}

/* Overlay scuro professionale */
.partner-page::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
}

.partner-page h1 {
    font-size: clamp(2rem, 3vw, 2.5rem);
    margin-bottom: clamp(70px, 8vw, 110px);
    font-weight: 600;
}

.partner-page h1,
.partner-grid {
    position: relative;
    z-index: 2;
}

.partner-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 60px;
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    align-items: center;
}

.partner-item {
    background: white;
    padding: 50px;
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 160px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.partner-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.partner-content p {
    margin-top: 10px;
    font-size: 0.95rem;
    color: #000; /* nero, visto che lo sfondo è bianco */
    font-weight: 500;
}

.partner-item:hover {
    transform: translateY(-6px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
}

.partner-item img {
    max-height: 90px;
    max-width: 100%;
    object-fit: contain;
}


/* ============================= */
/* RESPONSIVE */
/* ============================= */

@media (max-width: 1200px) {
    .buttons-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 50px;
    }

    .buttons-container img {
        max-width: 260px;
    }
}

@media (max-width: 768px) {

    .buttons-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;              /* meno spazio tra i bottoni */
        padding: 0 10px 50px 10px; /* meno spazio ai lati */
    }

    .buttons-container img {
        max-width: 100%;   /* ora occupano tutta la colonna */
        width: 100%;
    }

    .footer-logo img {
        height: 60px;
    }

    .footer-logo span {
        font-size: 1.6rem;
    }

    footer {
        padding: 50px 20px;
    }
}

@media (max-width: 1200px) {

    .footer-info {
        flex-wrap: wrap;
        justify-content: center;
        text-align: center;
    }

    .footer-block {
        align-items: center;
    }
}

@media (max-width: 768px) {

    .buttons-container {
        grid-template-columns: repeat(2, 1fr); /* minimo 2 per riga */
        gap: 30px;
        padding: 0 20px 50px 20px;
    }

    .buttons-container img {
        max-width: 180px;  /* grande ma non enorme */
        width: 100%;
    }

    .footer-info {
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }
}

@media (max-width: 768px) {

    .service-content {
        padding: 35px 20px;
        text-align: left; /* più professionale */
    }

    .service-content h1 {
        font-size: 1.6rem;
        margin-bottom: 15px;
    }

    .service-content h2 {
        font-size: 1rem;
        margin-bottom: 20px;
    }

    .service-content h3 {
        font-size: 0.95rem;
        margin-top: 25px;
    }

    .service-content p,
    .service-content li {
        font-size: 0.9rem;
        line-height: 1.6;
    }

}

/* ============================= */
/* MOBILE TYPOGRAPHY REFINEMENT */
/* ============================= */

@media (max-width: 768px) {

    body {
        font-size: 14px; /* base più piccola e proporzionata */
    }

    .hero h1 {
        font-size: 1.6rem;
    }

    .hero h2 {
        font-size: 1rem;
    }

    .hero p {
        font-size: 0.85rem;
        margin-bottom: 25px;
    }

    .service-content h1 {
        font-size: 1.4rem;
    }

    .service-content h2 {
        font-size: 1rem;
    }

    .service-content h3 {
        font-size: 0.9rem;
    }

    .service-content p,
    .service-content li {
        font-size: 0.85rem;
        line-height: 1.55;
    }

    .footer-block strong {
        font-size: 0.95rem;
    }

    .footer-block span,
    .footer-block a {
        font-size: 0.85rem;
    }

}