/* --------------------------------------------------
   GRIGLIA PRINCIPALE — ACTIS SMART
-------------------------------------------------- */
body.acquisizione-page .menu-grid {
    margin-top: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
    padding: 20px;
    max-width: 1100px;
    margin-left: auto;
    margin-right: auto;
    justify-items: center;
    width: 100%;
}

/* --------------------------------------------------
   CARD PRINCIPALI
-------------------------------------------------- */
body.acquisizione-page .menu-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    box-shadow: 0 3px 8px rgba(0,0,0,0.08);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    width: 100%;
    max-width: 320px;
}

body.acquisizione-page .menu-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}

body.acquisizione-page .menu-card h2 {
    margin-bottom: 10px;
    font-size: 22px;
}

body.acquisizione-page .menu-card p {
    margin: 0;
    font-size: 14px;
    color: #555;
}

/* --------------------------------------------------
   PAGE CONTENT
-------------------------------------------------- */
body.acquisizione-page .page-content {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
}

body.acquisizione-page {
    overflow-x: hidden;
}

/* --------------------------------------------------
   RESPONSIVE — TABLET
-------------------------------------------------- */
@media (max-width: 1023px) {
    body.acquisizione-page .menu-grid {
        padding: 16px;
        gap: 22px;
    }
}

/* --------------------------------------------------
   RESPONSIVE — MOBILE
-------------------------------------------------- */
@media (max-width: 600px) {

    body.acquisizione-page .page-content {
        padding: 0 12px;
    }

    body.acquisizione-page .menu-grid {
        grid-template-columns: 1fr;
        padding: 0 12px;
        gap: 20px;
        max-width: 100%;
    }

    body.acquisizione-page .menu-card {
        max-width: 340px;
        margin: 0 auto;
        box-sizing: border-box;
    }
}

/* --------------------------------------------------
   MOBILE ORIZZONTALE
-------------------------------------------------- */
@media (max-height: 480px) {
    body.acquisizione-page .menu-card h2 {
        font-size: 20px;
    }
}

/* --------------------------------------------------
   HARD FIX — elimina scroll orizzontale
-------------------------------------------------- */
body.acquisizione-page,
body.acquisizione-page * {
    box-sizing: border-box !important;
    max-width: 100% !important;
}

/* --------------------------------------------------
   POPUP — INIZIA ACQUISIZIONE
-------------------------------------------------- */

#acq-popup,
#popup-tipo {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

#popup-tipo .popup-content {
    background: white;
    width: 90%;
    max-width: 420px;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}

#popup-tipo label {
    font-weight: 600;
    margin-top: 12px;
    display: block;
}

#popup-tipo input,
#popup-tipo select {
    width: 100%;
    padding: 10px;
    margin-top: 6px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 16px;
}

#popup-tipo .popup-buttons {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

#popup-tipo .btn-annulla {
    flex: 1;
    padding: 10px;
    background: #ccc;
    border-radius: 8px;
    border: none;
    cursor: pointer;
}

#popup-tipo .btn-conferma {
    flex: 1;
    padding: 10px;
    background: #0078ff;
    color: white;
    border-radius: 8px;
    border: none;
    cursor: pointer;
}

/* --------------------------------------------------
   GPS RESULT
-------------------------------------------------- */
.gps-result {
    display: none;
    margin-top: 15px;
    text-align: center;
}

/* --------------------------------------------------
   POPUP — INIZIA ACQUISIZIONE (VERSIONE MIGLIORATA)
-------------------------------------------------- */

#popup-tipo {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.55);
    display: none;              /* 👈 NASCOSTO di default */
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

#popup-tipo .popup-content {
    background: #ffffff;
    width: 95%;
    max-width: 520px;          /* 🔵 più grande */
    padding: 35px 30px;        /* 🔵 più aria */
    border-radius: 14px;       /* 🔵 più elegante */
    box-shadow: 0 6px 18px rgba(0,0,0,0.28);
    animation: popupFade 0.25s ease-out;
}

@keyframes popupFade {
    from { transform: scale(0.95); opacity: 0; }
    to   { transform: scale(1); opacity: 1; }
}

#popup-tipo h2 {
    margin-bottom: 18px;
    font-size: 1.4rem;         /* 🔵 titolo più grande */
    font-weight: 600;
    color: #0d47a1;            /* blu profondo ACTIS */
}

#popup-tipo label {
    font-weight: 600;
    margin-top: 16px;
    display: block;
    font-size: 1rem;
}

#popup-tipo input,
#popup-tipo select {
    width: 100%;
    padding: 12px 14px;        /* 🔵 campi più comodi */
    margin-top: 8px;
    border-radius: 10px;
    border: 1px solid #ccc;
    font-size: 1rem;
}

#popup-tipo .popup-buttons {
    display: flex;
    gap: 14px;
    margin-top: 28px;
}

#popup-tipo .btn-annulla,
#popup-tipo .btn-conferma {
    flex: 1;
    padding: 12px 0;           /* 🔵 pulsanti più grandi */
    border-radius: 10px;
    border: none;
    cursor: pointer;
    font-size: 1.05rem;
}

#popup-tipo .btn-annulla {
    background: #e0e0e0;
}

#popup-tipo .btn-conferma {
    background: #0d47a1;
    color: white;
}

.messaggio-foto {
    background: #e6f0ff;
    border-left: 4px solid #1a3c6e;
    padding: 12px 16px;
    border-radius: 8px;
    color: #1a3c6e;
    font-weight: 600;
    margin-bottom: 18px;
    font-size: 15px;
    display: none;
}
