/* Sistema comune dei tre siti, prima per il telefono. Aria da etichetta alimentare nordica: bianco caldo, nero pieno,
   righe nette e un accento per paese preso dal cibo (.sito-xx: lingon, aneto, molte). Inter servito da qui, cifre
   tabellari per tutti i numeri. Niente foto, niente gradienti. */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap;
    src: url("fonts/inter-latin-Gz7AlRl.woff2") format("woff2");
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap;
    src: url("fonts/inter-latin-ext-1Br77OV.woff2") format("woff2");
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
    color-scheme: light dark;
    --carta: #faf8f3;
    --carta-chiara: #ffffff;
    --inchiostro: #0d0d0c;
    --testo: #1b1a18;
    --tenue: #5d5a55;
    --linea: #e2ddd3;
    --traccia: #ece8df;
    --grigio: #b8b1a5;
    --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --misura: 40rem;
}
.sito-se { --accento: #a3202c; --velo: #f6e6e4; }
.sito-dk { --accento: #2f6b3a; --velo: #e5efe4; }
.sito-no { --accento: #a84d00; --velo: #f6eadc; }
@media (prefers-color-scheme: dark) {
    :root { --carta: #141311; --carta-chiara: #1c1a17; --inchiostro: #f6f3ec; --testo: #e9e5dc; --tenue: #a39d93; --linea: #34312c; --traccia: #2a2824; --grigio: #6f6a61; }
    .sito-se { --accento: #f08a8f; --velo: #3a1f20; }
    .sito-dk { --accento: #8fcf98; --velo: #1d2f20; }
    .sito-no { --accento: #f2a65a; --velo: #392818; }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; background: var(--carta); color: var(--testo); font: 1.0625rem/1.55 var(--sans); font-feature-settings: "cv11", "ss03"; }
a { color: var(--accento); text-decoration-thickness: 1px; text-underline-offset: .2em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--accento); outline-offset: 3px; border-radius: 3px; }
h1, h2, h3 { color: var(--inchiostro); font-weight: 750; line-height: 1.12; letter-spacing: -.022em; }
h1 { margin: 0; font-size: clamp(2rem, 8.5vw, 3.25rem); overflow-wrap: break-word; hyphens: manual; }
h2 { margin: 0 0 .9rem; font-size: 1.25rem; }
h3 { margin: 1.25rem 0 .6rem; font-size: 1rem; }
p { margin: 0 0 1rem; }
p:last-child { margin-bottom: 0; }
small { font-size: .8125rem; }
button, input { font: inherit; }
table, .voce-kcal, .voce-valore, .kcal, .porzione-g, .porzione-kcal, .chips small, .cifre, .duello-kcal { font-variant-numeric: tabular-nums; }
.nascosto { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.salta { position: absolute; left: -999px; top: .5rem; z-index: 10; background: var(--inchiostro); color: var(--carta); padding: .7rem 1rem; }
.salta:focus { left: .5rem; }
.riga, .pagina { width: 100%; max-width: 72rem; margin-inline: auto; padding-inline: 1.25rem; }
.kicker { display: block; margin: 0 0 .5rem; font-weight: 700; font-size: .75rem; line-height: 1.3; letter-spacing: .12em; text-transform: uppercase; color: var(--accento); }

/* Testata: marchio e menu; sul telefono il menu va a capo sotto il marchio */
.testata { border-bottom: 2px solid var(--inchiostro); }
.testata-riga { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; column-gap: 2rem; padding-block: .5rem 0; }
.marchio { display: inline-flex; align-items: center; gap: .55rem; min-height: 48px; color: var(--inchiostro); text-decoration: none; }
.marchio-segno { display: inline-grid; place-items: center; min-width: 2.6rem; height: 1.6rem; padding-inline: .3rem; background: var(--accento); color: var(--carta);
    font-weight: 800; font-size: .75rem; letter-spacing: .02em; }
.marchio-nome { font-weight: 800; font-size: 1.3rem; letter-spacing: -.03em; }
.marchio-nome em { font-style: normal; font-weight: 400; }
.menu { width: 100%; }
.menu ul { display: flex; flex-wrap: wrap; column-gap: 1.1rem; margin: 0; padding: 0; list-style: none; white-space: nowrap; }
.menu a { display: inline-flex; align-items: center; gap: .4rem; min-height: 44px; color: var(--testo); font-weight: 600; font-size: .9375rem; text-decoration: none;
    border-bottom: 3px solid transparent; }
.menu a:hover { color: var(--accento); }
.menu a[aria-current] { color: var(--inchiostro); border-bottom-color: var(--accento); }
.menu svg { flex: none; }

/* Briciole e testa della pagina */
.percorso ol { display: flex; flex-wrap: wrap; gap: .15rem .5rem; margin: 0; padding: 1rem 0 0; list-style: none; font-size: .875rem; color: var(--tenue); }
.percorso li + li::before { content: "/"; margin-right: .5rem; color: var(--grigio); }
.percorso a { color: var(--tenue); }
.percorso [aria-current] { color: var(--testo); }
.kop, .held { padding-block: 1.25rem 1.5rem; max-width: 48rem; }
.held { padding-top: 2.25rem; }
.held h1 { font-size: clamp(2.2rem, 10vw, 3.75rem); }
.lead { margin: .8rem 0 0; font-size: 1.125rem; color: var(--testo); max-width: var(--misura); }
.latino { margin: .4rem 0 0; color: var(--tenue); font-style: italic; }

/* Ricerca */
.cerca { margin-block: 1.25rem 2rem; max-width: 36rem; }
.held .cerca { margin-bottom: 0; }
.cerca label { display: block; margin-bottom: .4rem; font-weight: 600; }
.cerca-riga { display: flex; border: 2px solid var(--inchiostro); background: var(--carta-chiara); }
.cerca input { flex: 1; min-width: 0; min-height: 52px; padding: 0 .9rem; border: 0; background: transparent; color: var(--inchiostro); font-size: 1.0625rem; }
.cerca input:focus { outline: none; }
.cerca-riga:focus-within { outline: 3px solid var(--accento); outline-offset: 2px; }
.cerca button, .libero-form button { min-height: 52px; padding: 0 1.2rem; border: 0; background: var(--inchiostro); color: var(--carta); font-weight: 700; cursor: pointer; }
.cerca button:hover, .libero-form button:hover { background: var(--accento); }
.hint { margin-top: .5rem; color: var(--tenue); font-size: .9375rem; }

/* Blocchi, link a chip, note */
.blokk { margin-block: 2rem; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0; padding: 0; list-style: none; }
.chips a, .chips span { display: inline-flex; align-items: baseline; gap: .4rem; min-height: 44px; padding: .6rem .85rem; border: 1px solid var(--linea); background: var(--carta-chiara);
    color: var(--inchiostro); text-decoration: none; font-weight: 550; line-height: 1.3; }
.chips a:hover { border-color: var(--inchiostro); }
.chips small { color: var(--tenue); font-weight: 400; white-space: nowrap; }
.chips-forti span, .chips-forti a { border-color: var(--inchiostro); font-weight: 700; }
.videre { margin-block: 1rem; font-weight: 600; }
.videre small { color: var(--tenue); font-weight: 400; }
.nota { color: var(--tenue); font-size: .875rem; }
.attribuzione { margin-block: 2rem 1rem; padding-top: .9rem; border-top: 1px solid var(--linea); color: var(--tenue); font-size: .8125rem; }
.attribuzione p { margin-bottom: .4rem; }
.attribuzione a { color: var(--tenue); }
.avviso { padding: .75rem 1rem; border-left: 4px solid var(--accento); background: var(--velo); }

/* Avvertenza fissa di filtri, allergeni e prodotti */
.avvertenza { display: flex; gap: .7rem; align-items: flex-start; margin: 1.25rem 0 0; padding: .9rem 1rem; max-width: var(--misura);
    border: 2px solid var(--inchiostro); background: var(--carta-chiara); font-size: .9375rem; line-height: 1.45; }
.avvertenza svg { flex: none; margin-top: .05rem; color: var(--accento); }

/* Testa dell'alimento: kcal grandi */
.scheda { margin-bottom: 1.75rem; }
.kcal { display: flex; align-items: flex-end; gap: .6rem; margin: 0; color: var(--inchiostro); }
.kcal-numero { font-size: clamp(4.5rem, 24vw, 7.5rem); font-weight: 800; line-height: .82; letter-spacing: -.055em; }
.kcal-unita { display: flex; flex-direction: column; padding-bottom: .2rem; font-size: 1.5rem; font-weight: 750; line-height: 1; letter-spacing: -.02em; }
.kcal-unita small { margin-top: .3rem; color: var(--tenue); font-size: .875rem; font-weight: 500; letter-spacing: 0; }
.kcal-altro { margin: .9rem 0 0; color: var(--tenue); font-variant-numeric: tabular-nums; }
.kcal-altro strong { color: var(--inchiostro); font-weight: 650; }
.macro { margin-top: 1.4rem; }
.macro-titolo { margin-bottom: .45rem; font-size: .75rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--tenue); }
.macro-barra { display: flex; height: .55rem; gap: 2px; background: var(--carta); }
.macro-barra span { display: block; min-width: 2px; }
.m-proteine { --m: var(--accento); }
.m-grassi { --m: var(--inchiostro); }
.m-carboidrati { --m: var(--grigio); }
.m-alcol { --m: var(--velo); }
.m-fibre { --m: var(--linea); }
.macro-barra span { background: var(--m); }
.macro-voci { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .9rem 1rem; margin: 1rem 0 0; }
.macro-voci div { padding-left: .65rem; border-left: 4px solid var(--m); }
.macro-voci .m-fibre { border-left: 1px dashed var(--grigio); }
.macro-voci dt { font-size: .8125rem; color: var(--tenue); }
.macro-voci dd { margin: 0; display: flex; align-items: baseline; gap: .4rem; }
.macro-g { font-size: 1.25rem; font-weight: 700; color: var(--inchiostro); font-variant-numeric: tabular-nums; }
.macro-voci small { color: var(--tenue); font-variant-numeric: tabular-nums; }
.segni { margin: 1.2rem 0 0; padding: 0; list-style: none; font-size: .9375rem; }
.segni li { padding-left: 1rem; position: relative; }
.segni li::before { content: ""; position: absolute; left: 0; top: .6em; width: .4rem; height: .4rem; background: var(--accento); }
.fatti { display: grid; gap: .5rem; margin: 1.2rem 0 0; }
.fatti div { display: flex; gap: .75rem; }
.fatti dt { min-width: 8rem; color: var(--tenue); }
.fatti dd { margin: 0; font-weight: 600; }

/* "100 kcal = X g": riquadro sotto le kcal e, nel confronto, i due alimenti a pari energia */
.cento { display: flex; flex-wrap: wrap; align-items: baseline; gap: .2rem .8rem; margin: 1.3rem 0 0; padding: .7rem .9rem; border: 2px solid var(--inchiostro);
    background: var(--carta-chiara); max-width: 34rem; }
.cento-titolo { flex: 1 0 100%; font-size: .75rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--tenue); }
.cento-valore { display: inline-flex; align-items: baseline; gap: .6rem; font-variant-numeric: tabular-nums; }
.cento-valore strong { font-size: 1.5rem; font-weight: 800; color: var(--inchiostro); letter-spacing: -.02em; }
.cento-misura { font-weight: 600; color: var(--inchiostro); }
.cento small, .cento-confronto small { color: var(--tenue); }
.cento-confronto { margin-block: 1.5rem; max-width: 40rem; }
.cento-confronto ul { margin: 0; padding: 0; list-style: none; border-top: 2px solid var(--inchiostro); }
.cento-confronto li { display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem 1rem; padding: .75rem 0; border-bottom: 1px solid var(--linea); }
.cento-nome { flex: 1 1 10rem; font-weight: 650; color: var(--inchiostro); }
.cento-confronto .barra { flex: 1 0 100%; height: 6px; }
.cento-confronto small { flex: 1 0 100%; }

/* Tabella stile etichetta: cornice nera, riga spessa sotto il titolo e sotto l'energia */
.etichetta { margin-block: 1.75rem; padding: .7rem .8rem .8rem; border: 2px solid var(--inchiostro); background: var(--carta-chiara); max-width: 34rem; }
.etichetta-titolo { margin: 0; padding-bottom: .45rem; border-bottom: 9px solid var(--inchiostro); font-size: 1.5rem; font-weight: 850; letter-spacing: -.03em; }
.etichetta table { width: 100%; border-collapse: collapse; }
.etichetta thead th { padding: .4rem 0 .35rem; border-bottom: 1px solid var(--inchiostro); font-size: .8125rem; font-weight: 700; text-align: right; }
.etichetta thead th:first-child { text-align: left; }
.etichetta tbody th, .etichetta td { padding: .4rem 0; border-bottom: 1px solid var(--inchiostro); vertical-align: top; }
.etichetta tbody th { text-align: left; font-weight: 600; }
.etichetta td { padding-left: .6rem; text-align: right; white-space: nowrap; font-weight: 600; }
.riga-energia th, .riga-energia td { border-bottom-width: 4px !important; font-weight: 800 !important; }
.kj { display: block; color: var(--tenue); font-size: .8125rem; font-weight: 500; }
.riga-rientro th { padding-left: 1rem; font-weight: 400 !important; }
.riga-rientro td { font-weight: 400 !important; }
.etichetta-altri tr:first-child th { padding-top: .9rem; border-bottom: 4px solid var(--inchiostro); font-size: .8125rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.etichetta-altri th { font-weight: 500; }
.etichetta-altri tr:last-child th, .etichetta-altri tr:last-child td { border-bottom: 0; }
.rif { display: flex; align-items: center; gap: .5rem; margin-top: .3rem; }
.rif small { color: var(--tenue); font-weight: 400; line-height: 1.3; }
.rif .barra { flex: 0 0 2.5rem; min-width: 0; }
.tipo { margin-left: .2rem; color: var(--tenue); font-size: .75rem; font-weight: 500; text-decoration: none; }
.etichetta + .nota, .etichetta .nota { margin-top: .7rem; }

/* Barre sottili: classifiche, confronti, fabbisogno */
.barra { display: block; flex: 1; height: 4px; background: var(--traccia); min-width: 3rem; }
.barra > span { display: block; height: 100%; background: var(--accento); }

/* Elenchi di alimenti e prodotti */
.voci { margin: 0; padding: 0; list-style: none; border-top: 2px solid var(--inchiostro); }
.voce a { display: flex; flex-wrap: wrap; align-items: last baseline; gap: .25rem 1rem; min-height: 48px; padding: .7rem 0; border-bottom: 1px solid var(--linea);
    color: var(--inchiostro); text-decoration: none; }
.voce a:hover .voce-nome { color: var(--accento); text-decoration: underline; text-underline-offset: .2em; }
.voce-nome { flex: 1 1 12rem; font-weight: 550; }
.voce-marca { display: block; color: var(--tenue); font-size: .75rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.voce-kcal, .voce-valore { margin-left: auto; font-weight: 700; white-space: nowrap; }
.voce-kcal small { color: var(--tenue); font-weight: 400; }
.voci-classifica { counter-reset: posto; }
.voci-classifica .voce a { padding-left: 2.4rem; position: relative; }
.voci-classifica .voce a::before { counter-increment: posto; content: counter(posto); position: absolute; left: 0; top: .7rem; width: 1.9rem; color: var(--tenue);
    font-weight: 700; font-variant-numeric: tabular-nums; }
.voci-classifica .voce a[data-posto]::before { content: attr(data-posto); }
.voci-classifica .barra { flex: 1 0 100%; order: 3; }

/* Porzioni */
.porzioni { margin: 0; padding: 0; list-style: none; border-top: 2px solid var(--inchiostro); }
.porzioni li { display: flex; align-items: baseline; gap: 1rem; min-height: 48px; padding: .7rem 0; border-bottom: 1px solid var(--linea); }
.porzione-nome { flex: 1; font-weight: 600; }
.porzioni a { flex: 1; color: var(--accento); }
.porzioni a .porzione-nome { flex: none; }
.porzione-g { color: var(--tenue); }
.porzione-kcal { min-width: 5rem; text-align: right; font-weight: 700; color: var(--inchiostro); }
.porzione-kcal small { color: var(--tenue); font-weight: 400; }

/* Tabelle larghe: categorie, altre fonti, confronto */
.tabella-scorre { overflow-x: auto; margin-inline: -1.25rem; padding-inline: 1.25rem; }
.tabella-alimenti, .riscontri, .confronto { width: 100%; border-collapse: collapse; border-top: 2px solid var(--inchiostro); font-size: .9375rem; }
.tabella-alimenti th, .tabella-alimenti td, .riscontri th, .riscontri td, .confronto th, .confronto td { padding: .65rem .5rem; border-bottom: 1px solid var(--linea); text-align: right; vertical-align: top; }
.tabella-alimenti th:first-child, .riscontri th:first-child, .confronto th:first-child { padding-left: 0; text-align: left; }
.tabella-alimenti td:last-child, .riscontri td:last-child, .confronto td:last-child { padding-right: 0; }
.tabella-alimenti thead th, .riscontri thead th, .confronto thead th { font-size: .8125rem; font-weight: 700; color: var(--tenue); white-space: nowrap; }
.tabella-alimenti tbody th { font-weight: 550; }
.tabella-alimenti tbody th a { color: var(--inchiostro); text-decoration: none; }
.tabella-alimenti tbody th a:hover { color: var(--accento); text-decoration: underline; }
.col-kcal { font-weight: 750; color: var(--inchiostro); }
.riscontri tbody th small { display: block; color: var(--tenue); font-weight: 400; }
/* Altre fonti: 7 colonne, sul telefono si scorre di lato con la fonte sempre in vista */
.riscontri td { white-space: nowrap; }
.riscontri th:first-child { position: sticky; left: 0; z-index: 1; min-width: 7.5rem; max-width: 11rem; padding-right: .75rem; background: var(--carta); }
.scorri { margin: 0 0 .5rem; }
.riga-propria th, .riga-propria td { font-weight: 700; color: var(--inchiostro); }
.divergenza { margin-top: .9rem; padding-left: .8rem; border-left: 4px solid var(--accento); font-size: .9375rem; }

/* Confronto: due colonne con le kcal grandi, poi le righe con le barre */
.duello { display: grid; grid-template-columns: 1fr 1fr; border: 2px solid var(--inchiostro); margin-bottom: 1rem; }
.duello-lato { display: flex; flex-direction: column; gap: .2rem; padding: .9rem; color: var(--inchiostro); text-decoration: none; }
.duello-lato + .duello-lato { border-left: 2px solid var(--inchiostro); }
.duello-nome { font-weight: 700; line-height: 1.2; }
.duello-lato:hover .duello-nome { color: var(--accento); text-decoration: underline; }
.duello-kcal { font-weight: 700; }
.duello-kcal .kcal-numero { font-size: clamp(2.5rem, 12vw, 4rem); }
.duello small { color: var(--tenue); }
.duello-b .barra > span, .barra-b > span { background: var(--inchiostro); }
.sintesi { font-size: 1.0625rem; font-weight: 600; }
.confronto td span:first-child { display: block; }
.confronto td .barra { margin-top: .3rem; margin-left: auto; max-width: 8rem; }
.confronto td.piu { font-weight: 750; color: var(--inchiostro); }
.confronto .riga-rientro th { padding-left: 1rem; font-weight: 400; }
.libero-form { display: grid; gap: .9rem; max-width: 36rem; }
.libero-form p { margin: 0; }
.libero-form label { display: block; margin-bottom: .35rem; font-weight: 600; }
.libero-form input { width: 100%; min-height: 52px; padding: 0 .9rem; border: 2px solid var(--inchiostro); background: var(--carta-chiara); color: var(--inchiostro); }
.libero-form input:focus { outline: 3px solid var(--accento); outline-offset: 2px; }
.libero-form button { justify-self: start; }

/* Categorie */
.gruppi { display: grid; gap: 1.5rem; margin-bottom: 2rem; }
.gruppo { padding-top: .8rem; border-top: 2px solid var(--inchiostro); }
.gruppo h2 a { color: var(--inchiostro); text-decoration: none; }
.gruppo h2 a:hover { color: var(--accento); text-decoration: underline; }
.gruppo h2 small { color: var(--tenue); font-weight: 500; font-variant-numeric: tabular-nums; }

/* Pagine di testo */
.tekst { max-width: var(--misura); }
.tekst .blokk { margin-block: 1.5rem 2rem; }

/* Piede */
.piede { margin-top: 3rem; border-top: 2px solid var(--inchiostro); background: var(--carta-chiara); }
.piede-riga { display: grid; gap: 1.25rem; padding-block: 1.75rem 2.25rem; font-size: .9375rem; }
.piede-marchio p { margin-top: .4rem; color: var(--tenue); }
.piede-link { display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; }
.piede-link a { display: inline-flex; align-items: center; min-height: 44px; color: var(--inchiostro); font-weight: 600; }
.piede-fonti, .piede-nota { margin: 0; color: var(--tenue); font-size: .8125rem; }
.piede-fonti a { color: var(--tenue); }

@media (min-width: 40rem) {
    .riga, .pagina { padding-inline: 2rem; }
    .tabella-scorre { margin-inline: 0; padding-inline: 0; }
    .scorri { display: none; }
    .macro-voci { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .gruppi { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem; }
    .libero-form { grid-template-columns: 1fr 1fr auto; align-items: end; max-width: none; }
    .etichetta { padding: .9rem 1.1rem 1rem; }
}
@media (min-width: 60rem) {
    .testata-riga { flex-wrap: nowrap; padding-block: .25rem; }
    .menu { width: auto; }
    .colonne { display: grid; grid-template-columns: minmax(0, 1fr) 20rem; gap: 3.5rem; align-items: start; }
    .laterale { padding-top: .25rem; }
    .laterale .blokk:first-child { margin-top: 0; }
    .gruppi { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .piede-riga { grid-template-columns: 1.2fr 1fr; column-gap: 3rem; }
    .piede-fonti, .piede-nota { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: no-preference) {
    a, .chips a { transition: color .15s, border-color .15s; }
}
@media print {
    .testata, .piede, .cerca, .laterale, .libero { display: none; }
}
