/* ricettedelcuore.it */
:root {
  --terra: #b5462f;
  --terra-dark: #8e3322;
  --olive: #5b6b2f;
  --cream: #fbf6ef;
  --paper: #ffffff;
  --ink: #2b2420;
  --muted: #6f655d;
  --line: #e8ddd0;
  --gold: #c99a2e;
  --radius: 12px;
  --shadow: 0 6px 24px rgba(60, 35, 20, .14);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --header-h: 60px;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--sans); color: var(--ink); background: var(--cream); line-height: 1.55; font-size: 16px; }
a { color: var(--terra); }
a:hover { color: var(--terra-dark); }
img { max-width: 100%; height: auto; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.2; color: var(--ink); }
h1 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); margin: .2em 0 .4em; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff; padding: 8px 12px; z-index: 9999; }
.skip-link:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* Header */
.site-header {
  height: var(--header-h); display: flex; align-items: center; justify-content: space-between;
  padding: 0 20px; background: var(--paper); border-bottom: 1px solid var(--line); position: relative; z-index: 1000;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand-name { font-family: var(--serif); font-size: 1.35rem; font-weight: 700; letter-spacing: .2px; }
.brand-name em { color: var(--terra); font-style: italic; font-weight: 400; }
.main-nav { display: flex; gap: 4px; }
.main-nav a { text-decoration: none; color: var(--ink); padding: 8px 14px; border-radius: 999px; font-weight: 500; }
.main-nav a:hover { background: var(--cream); }
.main-nav a.active { background: var(--terra); color: #fff; }
.nav-toggle { display: none; background: none; border: 1px solid var(--line); border-radius: 8px; font-size: 1.3rem; padding: 4px 10px; cursor: pointer; }
@media (max-width: 700px) {
  .nav-toggle { display: block; }
  .main-nav { display: none; position: absolute; top: var(--header-h); right: 0; left: 0; flex-direction: column; background: var(--paper); border-bottom: 1px solid var(--line); padding: 8px; }
  .main-nav.open { display: flex; }
  .brand-name { font-size: 1.15rem; }
}

/* Flash e toast */
.flash { max-width: 960px; margin: 14px auto 0; padding: 12px 16px; border-radius: 10px; background: #eef3e2; border: 1px solid #cdd9b0; }
.flash-error { background: #fbeae6; border-color: #efc1b6; }
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 3000; max-width: min(560px, 92vw);
  background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 10px; box-shadow: var(--shadow); font-size: .95rem;
}
.toast-ok { background: var(--olive); }
.toast-error { background: var(--terra-dark); }

/* Bottoni */
.btn { display: inline-block; border: 1px solid transparent; border-radius: 999px; padding: 10px 20px; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; line-height: 1.2; }
.btn-primary { background: var(--terra); color: #fff; }
.btn-primary:hover { background: var(--terra-dark); color: #fff; }
.btn-primary:disabled { opacity: .6; cursor: wait; }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { background: var(--cream); }
.btn-danger { background: #fff; color: var(--terra-dark); border-color: #e5b4a8; }
.btn-danger:hover { background: #fbeae6; }
.btn-small { padding: 6px 12px; font-size: .88rem; }

/* ---------- Mappa ---------- */
.page-map { overflow: hidden; }
.map-wrap { position: relative; height: calc(100vh - var(--header-h)); height: calc(100dvh - var(--header-h)); }
#map { position: absolute; inset: 0; background: #dfe8ec; }
.map-search { position: absolute; top: 14px; left: 14px; z-index: 900; display: flex; width: min(380px, calc(100% - 28px)); box-shadow: var(--shadow); border-radius: 999px; background: #fff; }
.map-search input { flex: 1; border: 0; padding: 12px 18px; border-radius: 999px 0 0 999px; font: inherit; min-width: 0; }
.map-search button { border: 0; background: var(--terra); color: #fff; padding: 0 16px; border-radius: 0 999px 999px 0; cursor: pointer; font-size: 1rem; }
.search-results { position: absolute; top: 52px; left: 0; right: 0; list-style: none; margin: 0; padding: 6px; background: #fff; border-radius: 12px; box-shadow: var(--shadow); max-height: 300px; overflow: auto; }
.search-results button { display: block; width: 100%; text-align: left; border: 0; background: none; padding: 8px 10px; border-radius: 8px; cursor: pointer; font: inherit; font-size: .9rem; }
.search-results button:hover { background: var(--cream); }
.search-results .muted { padding: 8px 10px; color: var(--muted); font-size: .9rem; }
.map-hint {
  position: absolute; top: 14px; right: 14px; z-index: 800; max-width: 330px; background: rgba(255,255,255,.96);
  padding: 14px 36px 14px 16px; border-radius: var(--radius); box-shadow: var(--shadow); font-size: .9rem;
}
.hint-close { position: absolute; top: 6px; right: 8px; border: 0; background: none; font-size: 1.3rem; cursor: pointer; color: var(--muted); }
@media (max-width: 700px) {
  .map-hint { top: auto; bottom: 120px; left: 14px; right: 14px; max-width: none; }
  .map-legal { right: 70px; font-size: .68rem; }
}
.map-legend { position: absolute; left: 14px; bottom: 34px; z-index: 800; background: rgba(255,255,255,.92); border-radius: 999px; padding: 6px 12px; font-size: .82rem; display: flex; gap: 10px; box-shadow: var(--shadow); }
.map-legal { position: absolute; left: 14px; bottom: 8px; z-index: 800; font-size: .74rem; color: var(--muted); background: rgba(255,255,255,.8); padding: 1px 8px; border-radius: 6px; }
.map-legal a { color: var(--muted); }
@media (max-width: 700px) { .map-legend { display: none; } }

.rdc-pin { background: none; border: 0; }
.rdc-pin svg { filter: drop-shadow(0 2px 3px rgba(0,0,0,.35)); transition: transform .15s; transform-origin: 50% 100%; }
.rdc-pin:hover svg { transform: scale(1.15); }
.rdc-pin-new svg { animation: bob 1s ease-in-out infinite alternate; }
@keyframes bob { from { transform: translateY(0); } to { transform: translateY(-5px); } }
.marker-cluster-small, .marker-cluster-medium, .marker-cluster-large { background-color: rgba(181, 70, 47, .25) !important; }
.marker-cluster-small div, .marker-cluster-medium div, .marker-cluster-large div { background-color: var(--terra) !important; color: #fff; font-weight: 700; }

.rdc-popup .leaflet-popup-content-wrapper { border-radius: var(--radius); padding: 0; overflow: hidden; }
.rdc-popup .leaflet-popup-content { margin: 0; width: auto !important; min-width: 240px; }
.pop-img { display: block; width: 100%; height: 130px; object-fit: cover; }
.pop-body { padding: 12px 14px 10px; }
.pop-title { margin: 0 0 4px; font-size: 1.15rem; }
.pop-title a { color: var(--ink); text-decoration: none; }
.pop-title a:hover { color: var(--terra); }
.pop-place { margin: 0 0 6px !important; font-size: .78rem; color: var(--muted); }
.pop-desc { margin: 0 0 6px !important; font-size: .88rem; }
.pop-author { margin: 0 0 6px !important; font-size: .8rem; color: var(--muted); }
.pop-links { margin: 8px 0 0 !important; font-size: .85rem; }
.add-pop p { margin: 8px 0 !important; }
.add-pop { padding: 10px 14px 12px; }
.add-err { color: var(--terra-dark); }
.rdc-tooltip { border-radius: 10px; padding: 8px 10px; box-shadow: var(--shadow); }
.cluster-tip ol { margin: 6px 0; padding-left: 20px; }
.cluster-tip li { font-size: .85rem; }
.cluster-tip small { color: var(--muted); }

/* Voti */
.votes { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.vote-btn {
  display: inline-flex; align-items: center; gap: 4px; border: 1px solid var(--line); background: #fff; border-radius: 999px;
  padding: 4px 10px; cursor: pointer; font: inherit; font-size: .9rem; transition: transform .1s, background .15s, border-color .15s;
}
.vote-btn:hover { transform: translateY(-1px); border-color: #d6c4b0; }
.vote-btn:active { transform: scale(.94); }
.vote-heart .vote-ico { color: #d23a52; }
.vote-btn.is-active { background: #fff1e8; border-color: var(--terra); box-shadow: inset 0 0 0 1px var(--terra); font-weight: 700; }
.vote-heart.is-active { background: #ffe8ec; border-color: #d23a52; box-shadow: inset 0 0 0 1px #d23a52; }
.score { margin-left: auto; font-weight: 700; color: var(--olive); font-size: .9rem; }
.votes.pop .score { animation: pulse .4s; }
@keyframes pulse { 50% { transform: scale(1.25); } }

/* ---------- Drawer inserimento ---------- */
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(480px, 100vw); background: var(--paper); z-index: 2000;
  transform: translateX(105%); transition: transform .25s ease; box-shadow: -10px 0 40px rgba(0,0,0,.18); display: flex; flex-direction: column;
}
.drawer.open { transform: none; }
.drawer-backdrop { position: fixed; inset: 0; background: rgba(30,20,15,.35); z-index: 1999; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 20px; border-bottom: 1px solid var(--line); }
.drawer-head h2 { margin: 0; font-size: 1.35rem; }
.drawer-close { border: 0; background: none; font-size: 1.8rem; cursor: pointer; line-height: 1; color: var(--muted); }
.recipe-form { padding: 16px 20px 24px; overflow-y: auto; flex: 1; }
.place-badge { background: var(--cream); padding: 8px 12px; border-radius: 10px; margin: 0 0 6px; font-weight: 600; }

/* Form generici */
fieldset { border: 0; padding: 0; margin: 0 0 18px; }
legend { font-family: var(--serif); font-weight: 700; font-size: 1.1rem; margin-bottom: 6px; padding: 0; }
legend small, summary small { font-family: var(--sans); font-weight: 400; color: var(--muted); font-size: .8rem; }
label { display: block; font-weight: 600; font-size: .9rem; margin: 10px 0 4px; }
input[type=text], input[type=email], input[type=search], input[type=password], textarea, select {
  width: 100%; font: inherit; padding: 10px 12px; border: 1px solid #d9cdbf; border-radius: 10px; background: #fff; color: var(--ink);
}
textarea { resize: vertical; }
input:focus, textarea:focus, select:focus { border-color: var(--terra); outline: none; box-shadow: 0 0 0 3px rgba(181,70,47,.15); }
.has-error { border-color: var(--terra-dark) !important; background: #fff8f6 !important; }
.field-error { color: var(--terra-dark); font-size: .84rem; margin: 4px 0 0; }
.field-error:empty { display: none; }
.form-error { background: #fbeae6; border: 1px solid #efc1b6; padding: 10px 12px; border-radius: 10px; }
.help { color: var(--muted); font-size: .84rem; margin: 4px 0 8px; }
.req { color: var(--terra); }
label.check { display: block; position: relative; padding-left: 28px; font-weight: 400; font-size: .88rem; }
label.check input { position: absolute; left: 0; top: 1px; margin: 0; width: 18px; height: 18px; accent-color: var(--terra); }
.hp { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }
details.optional { border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; margin-bottom: 18px; }
details.optional summary { cursor: pointer; font-family: var(--serif); font-weight: 700; font-size: 1.05rem; }
.ing-row { display: grid; grid-template-columns: 1fr 120px 34px; gap: 6px; margin-bottom: 6px; }
.ing-del { border: 1px solid var(--line); background: #fff; border-radius: 8px; cursor: pointer; font-size: 1.1rem; color: var(--muted); }
.img-preview { display: block; max-height: 180px; border-radius: 10px; margin-top: 8px; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 14px; }
.consents { background: var(--cream); padding: 10px 14px; border-radius: var(--radius); }

/* ---------- Pagine di contenuto ---------- */
.container { max-width: 1040px; margin: 0 auto; padding: 24px 20px 48px; }
.container-narrow { max-width: 760px; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; margin-bottom: 18px; }
.muted { color: var(--muted); }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 6px; font-size: .92rem; margin: 0 0 6px; padding: 0; list-style: none; }
.breadcrumb li + li::before { content: "›"; margin-right: 6px; color: var(--muted); }
.breadcrumb [aria-current] { font-weight: 700; }

/* Classifica */
.rank-layout { display: grid; grid-template-columns: 1fr 280px; gap: 22px; align-items: start; }
@media (max-width: 860px) { .rank-layout { grid-template-columns: 1fr; } }
.rank-list { list-style: none; margin: 0; padding: 0; }
.rank-item { display: grid; grid-template-columns: 46px 84px 1fr; gap: 14px; align-items: center; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 10px; }
.rank-pos { font-family: var(--serif); font-size: 1.6rem; font-weight: 700; text-align: center; color: var(--muted); }
.rank-item:nth-child(1) .rank-pos { color: var(--gold); }
.rank-item:nth-child(2) .rank-pos { color: #9a9a9a; }
.rank-item:nth-child(3) .rank-pos { color: #b0743d; }
.rank-thumb { width: 84px; height: 64px; border-radius: 8px; object-fit: cover; background: var(--cream); display: flex; align-items: center; justify-content: center; font-size: 1.6rem; }
.rank-title { margin: 0; font-size: 1.15rem; }
.rank-title a { color: var(--ink); text-decoration: none; }
.rank-title a:hover { color: var(--terra); }
.rank-meta { margin: 2px 0 6px; font-size: .84rem; color: var(--muted); }
.rank-meta a { color: var(--muted); }
@media (max-width: 560px) { .rank-item { grid-template-columns: 34px 1fr; } .rank-thumb { display: none; } }
.sort-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0 16px; }
.sort-tabs a { text-decoration: none; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-size: .9rem; }
.sort-tabs a.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.area-list { list-style: none; margin: 0; padding: 0; max-height: 70vh; overflow: auto; }
.area-list li { display: flex; justify-content: space-between; gap: 8px; padding: 7px 4px; border-bottom: 1px dashed var(--line); font-size: .93rem; }
.area-list li:last-child { border-bottom: 0; }
.area-list small { color: var(--muted); white-space: nowrap; }
.side h2 { font-size: 1.15rem; margin-top: 0; }
.level-up { display: inline-block; margin-bottom: 10px; font-size: .9rem; }

/* Dettaglio ricetta */
.recipe-hero { width: 100%; max-height: 420px; object-fit: cover; border-radius: var(--radius); margin-bottom: 18px; }
.recipe-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 22px; }
@media (max-width: 760px) { .recipe-grid { grid-template-columns: 1fr; } }
.ing-table { width: 100%; border-collapse: collapse; }
.ing-table td { padding: 6px 4px; border-bottom: 1px dashed var(--line); }
.ing-table td:last-child { text-align: right; color: var(--muted); white-space: nowrap; }
.prep { white-space: pre-line; }
.recipe-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; align-items: center; }
.link-btn { border: 0; background: none; color: var(--muted); cursor: pointer; font: inherit; font-size: .85rem; text-decoration: underline; padding: 0; }

/* Tabelle admin / mie ricette */
.table { width: 100%; border-collapse: collapse; background: #fff; }
.table th, .table td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; font-size: .92rem; }
.table th { background: var(--cream); font-weight: 700; }
.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: .75rem; font-weight: 700; background: var(--cream); }
.badge-published { background: #e7efd5; color: #3d4a1b; }
.badge-pending { background: #fff2cc; color: #6b5200; }
.badge-hidden { background: #f3d7d0; color: #7a2615; }
.inline-form { display: inline; }

/* Pagine legali */
.legal h2 { font-size: 1.3rem; margin-top: 1.6em; }
.legal table { border-collapse: collapse; width: 100%; font-size: .92rem; }
.legal th, .legal td { border: 1px solid var(--line); padding: 8px; text-align: left; vertical-align: top; }
.legal th { background: var(--cream); }

/* Dialog */
.dialog { border: 0; border-radius: var(--radius); padding: 22px; width: min(440px, 92vw); box-shadow: var(--shadow); }
.dialog::backdrop { background: rgba(30,20,15,.4); }
.dialog h3 { margin-top: 0; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); background: var(--paper); padding: 22px 20px 14px; font-size: .9rem; }
.footer-inner { max-width: 1040px; margin: 0 auto; display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer-nav { display: flex; gap: 14px; flex-wrap: wrap; }
.footer-osm { max-width: 1040px; margin: 12px auto 0; color: var(--muted); font-size: .78rem; }
.mod-form { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.mod-form input[type=text] { width: auto; flex: 1; min-width: 160px; padding: 6px 10px; font-size: .85rem; }

/* Mappa stilizzata (confini ISTAT) */
#map.map-istat { background: #d7e7ee; }
.map-label { pointer-events: none; }
.map-label span {
  position: absolute; left: 0; top: 0; transform: translate(-50%, -50%); white-space: nowrap;
  font: 500 11.5px/1 var(--sans); color: #5f5248;
  text-shadow: 0 0 2px #f7f0e3, 0 0 2px #f7f0e3, 0 0 4px #f7f0e3, 0 0 4px #f7f0e3;
}
.map-label.below span { transform: translate(-50%, 4px); }
.map-label.below2 span { transform: translate(-50%, 24px); }
.map-label.above span { transform: translate(-50%, calc(-100% - 52px)); }
.map-label.lbl-cap span { font-weight: 700; font-size: 12.5px; color: #3a3029; }
.map-label.lbl-region span {
  font-family: var(--serif); font-size: 14px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: #8a7154;
}
.search-results small { color: var(--muted); }

/* Codice di gestione (ricette senza email) */
.claim-code { font: 700 1.7rem/1.2 ui-monospace, "Cascadia Mono", Consolas, monospace; letter-spacing: .12em; text-align: center;
  background: var(--cream); border: 2px dashed var(--terra); border-radius: 10px; padding: 12px; margin: 10px 0; user-select: all; }
.claim-dialog { width: min(520px, 94vw); }
.claim-dialog .form-actions { flex-wrap: wrap; }
.claim-hint { margin: 16px 0 0; padding: 10px 12px; background: var(--cream); border-radius: 10px; font-size: .9rem; }
.claim-hint.is-mine { background: #eef3e2; }

/* ---------- Temi della mappa stilizzata ---------- */
@font-face { font-family: "Caveat"; src: url("../fonts/caveat-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Playfair Display"; src: url("../fonts/playfair-600-italic.woff2") format("woff2"); font-weight: 600; font-style: italic; font-display: swap; }

.map-compass { position: absolute; left: 18px; bottom: 74px; z-index: 700; pointer-events: none; }
@media (max-width: 700px) { .map-compass { display: none; } }

/* Illustrata: regioni color pastello, mare a onde, nomi scritti a mano */
#map.theme-illustrata { background: radial-gradient(ellipse at 45% 40%, #e9f7f8 0%, #dff2f4 45%, #cfeaee 100%); }
#map.theme-illustrata .leaflet-land-pane canvas { filter: drop-shadow(0 3px 0 rgba(70, 120, 130, .28)); }
.map-wrap:has(.theme-illustrata) .map-compass { color: #3f8796; }
#map.theme-illustrata .map-label span { text-shadow: 0 0 2px #fff, 0 0 3px #fff, 0 0 5px #fff; color: #4b3a30; }
#map.theme-illustrata .map-label.lbl-region span {
  font: 700 25px/1 "Caveat", "Segoe Print", cursive; letter-spacing: .01em; text-transform: none; color: #7a3f2b;
  text-shadow: 0 0 3px #fff, 0 0 6px #fff, 0 0 8px rgba(255,255,255,.8);
}
#map.theme-illustrata .map-label.lbl-sea span { font: 700 21px/1 "Caveat", cursive; color: #2f7f8f; letter-spacing: .04em; text-shadow: none; opacity: .85; }
#map.theme-illustrata .map-label.lbl-cap span { color: #3b2a20; }

/* Vintage: carta antica, inchiostro seppia, corsivo */
#map.theme-vintage { background: #bcd3c9; }
#map.theme-vintage::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 650;
  box-shadow: inset 0 0 120px rgba(90, 60, 25, .35);
}
.map-wrap:has(.theme-vintage) .map-compass { color: #6f5232; }
#map.theme-vintage .map-label span { font-family: "Playfair Display", Georgia, serif; font-style: italic; font-weight: 600; color: #4e3720;
  text-shadow: 0 0 2px #efe0bd, 0 0 3px #efe0bd, 0 0 5px #efe0bd; }
#map.theme-vintage .map-label.lbl-region span { font-size: 15px; letter-spacing: .22em; text-transform: uppercase; color: #6b4a2b; }
#map.theme-vintage .map-label.lbl-sea span { font-size: 15px; letter-spacing: .15em; color: #3f6158; text-shadow: none; }

/* Selettore dello stile mappa */
.theme-ctl { position: relative; background: #fff; }
.theme-ctl-btn { display: block; width: 34px; height: 34px; border: 0; background: #fff; cursor: pointer; font-size: 17px; line-height: 34px; padding: 0; border-radius: 4px; }
.theme-ctl-btn:hover { background: #f4f4f4; }
.theme-menu { position: absolute; right: 44px; bottom: 0; background: #fff; border-radius: 12px; box-shadow: var(--shadow); padding: 8px; min-width: 180px; }
.theme-menu p { margin: 2px 6px 6px; font-weight: 700; font-size: .78rem; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.theme-menu button { display: flex; align-items: center; gap: 10px; width: 100%; border: 0; background: none; padding: 7px 8px; border-radius: 8px; font: inherit; font-size: .92rem; cursor: pointer; text-align: left; color: var(--ink); }
.theme-menu button:hover { background: var(--cream); }
.theme-menu button[aria-checked="true"] { background: var(--cream); font-weight: 700; }
.theme-menu button[aria-checked="true"]::after { content: "✓"; margin-left: auto; color: var(--terra); }
.sw { width: 26px; height: 26px; border-radius: 50%; border: 1px solid rgba(0,0,0,.12); flex-shrink: 0; }
.sw-illustrata { background: conic-gradient(#f6c9a8 0 25%, #cfe0b4 0 50%, #d9cdea 0 75%, #bfe3d3 0); }
.sw-vintage { background: radial-gradient(circle at 40% 40%, #efe0bd 50%, #b39869 100%); }
.sw-classica { background: linear-gradient(135deg, #f7f0e3 50%, #d7e7ee 50%); }

.optout { margin-top: 10px; }
.optout .stats-status { margin: 6px 0 0; font-size: .9rem; }

/* Foto con crediti */
.recipe-figure { margin: 0 0 18px; }
.recipe-figure .recipe-hero { margin-bottom: 4px; }
.photo-credit { font-size: .75rem; color: var(--muted); text-align: right; }
.photo-credit a { color: var(--muted); }
.badge-redazione { display: inline-block; margin-left: 4px; padding: 1px 7px; border-radius: 999px; background: var(--olive); color: #fff; font-size: .7rem; font-weight: 700; vertical-align: middle; }
/* Importazione */
.progress { height: 14px; background: var(--cream); border-radius: 999px; overflow: hidden; border: 1px solid var(--line); }
.progress > span { display: block; height: 100%; width: 0; background: var(--olive); transition: width .3s; }
.import-log { max-height: 320px; overflow: auto; font-size: .85rem; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; margin-top: 12px; }
.import-log div { padding: 2px 0; border-bottom: 1px dashed var(--line); }
.admin-thumb { float: left; margin-right: 8px; border-radius: 6px; object-fit: cover; }

/* Ricetta probabilmente gia' presente */
.dup-box { background: #fff6e0; border: 1px solid #ecd28f; border-radius: 10px; padding: 10px 12px; margin: 6px 0 10px; font-size: .9rem; }
.dup-box.is-blocking { background: #fbeae6; border-color: #efc1b6; }
.dup-box p { margin: 0 0 4px; }
.dup-box ul { margin: 4px 0 6px; padding-left: 18px; }
.dup-box .form-actions { margin-top: 8px; }
