/* ==========================================================================
   Footer unico di tutto il sito (markup in site/partials/footer.html).
   Classi proprie "pa-footer-*" e colori propri: non dipende dai fogli della pagina
   (styles.css, strumenti.css, calcolatore) e ha sempre il fondo cemento della home.
   ========================================================================== */
.pa-footer {
    --pf-concrete: #EDEFF2;
    --pf-chalk: #FBFBFC;
    --pf-iron: #1B1E24;
    --pf-steel: #5A6270;
    --pf-line: rgba(27, 30, 36, 0.10);
    --pf-brand: #FA7402;
    --pf-brand-ink: #B45309;
    --pf-ease-out: cubic-bezier(0.16, 1, 0.3, 1);

    margin: 0;
    padding: clamp(64px, 8vw, 96px) 0 32px;
    border: 0;
    background: var(--pf-concrete);
    color: var(--pf-iron);
    font-family: 'PerformFont6', system-ui, sans-serif;
    font-size: 1rem;
    line-height: 1.6;
    text-align: left;
}

.pa-footer-inner {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 clamp(16px, 4vw, 40px);
    box-sizing: border-box;
}

.pa-footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 48px;
    border-bottom: 1px solid var(--pf-line);
}

.pa-footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--pf-iron);
    font-weight: 800;
    font-size: 1.25rem;
    letter-spacing: -0.01em;
    text-decoration: none;
}
.pa-footer-logo img { width: 34px; height: 34px; border-radius: 9px; }

.pa-footer-brand p { margin: 16px 0 0; max-width: 32ch; color: var(--pf-steel); }

/* tre colonne: i contatti stanno sotto il marchio, non in una colonna con una sola voce */
.pa-footer-grid > .pa-footer-col:nth-child(2) { grid-column: 2; grid-row: 1 / span 2; }
.pa-footer-grid > .pa-footer-col:nth-child(3) { grid-column: 3; grid-row: 1 / span 2; }
.pa-footer-grid > .pa-footer-col:last-child { grid-column: 1; grid-row: 2; }

.pa-footer-col { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }

.pa-footer .pa-footer-title {
    margin: 0 0 6px;
    color: var(--pf-iron);
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0;
    text-transform: none;
}

.pa-footer-col a,
.pa-footer .pa-choice-footer-preferences {
    padding: 0;
    border: 0;
    background: none;
    color: var(--pf-steel);
    font: inherit;
    font-size: 0.95rem;
    font-weight: 400;
    line-height: inherit;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s ease;
}
.pa-footer-col a:hover,
.pa-footer .pa-choice-footer-preferences:hover { color: var(--pf-brand-ink); }

.pa-footer-bottom {
    display: flex;
    align-items: center;
    gap: 16px;
    padding-top: 24px;
    color: var(--pf-steel);
    font-size: 0.9rem;
}

.pa-footer-bottom p { margin: 0 auto 0 0; }

.pa-footer-top {
    order: 3;
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--pf-iron);
    color: #fff;
    text-decoration: none;
    transition: background-color 0.25s ease, color 0.25s ease, transform 0.4s var(--pf-ease-out);
}
.pa-footer-top:hover { background: var(--pf-brand); color: var(--pf-iron); transform: translateY(-3px); }

.pa-footer-language { order: 2; }

/* selettore lingua: stesso aspetto su tutte le pagine */
.pa-footer .language-switcher { color: var(--pf-iron); }
.pa-footer .language-switcher summary {
    border: 0;
    background: var(--pf-chalk);
    box-shadow: inset 0 0 0 1px var(--pf-line);
    color: var(--pf-iron);
    font-family: inherit;
}

.pa-footer a:focus-visible,
.pa-footer button:focus-visible,
.pa-footer summary:focus-visible { outline: 2px solid var(--pf-brand); outline-offset: 3px; }

@media (max-width: 920px) {
    .pa-footer-grid { grid-template-columns: 1fr 1fr; }
    .pa-footer-grid > .pa-footer-col:nth-child(n) { grid-column: auto; grid-row: auto; }
    .pa-footer-brand { grid-column: span 2; }
}

@media (max-width: 600px) {
    .pa-footer-grid { grid-template-columns: 1fr 1fr; gap: 32px 20px; }
    .pa-footer-brand, .pa-footer-grid > .pa-footer-col:last-child:nth-child(n) { grid-column: span 2; }
    .pa-footer-bottom { flex-wrap: wrap; }
    .pa-footer-bottom p { flex: 1 1 100%; order: 1; }
}
