/* ==========================================================================
   Diabete.com — design system
   White surfaces · ink #232323 · primary #007f91 · accent #fdba4d
   Single file, no preprocessor. Sections: tokens, base, shell, components,
   feed, article, centri, reading modes, transitions, print.
   ========================================================================== */

@font-face {
	font-family: "Geist";
	font-style: normal;
	font-weight: 100 900;
	font-display: swap;
	src: url("../fonts/geist-latin.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: "Geist";
	font-style: normal;
	font-weight: 100 900;
	font-display: swap;
	src: url("../fonts/geist-latin-ext.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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Tokens ---------- */
:root {
	--ink: #232323;
	--ink-strong: #121212;
	--muted: #6b6b6b;
	--faint: #9a9a97;
	--primary: #007f91;
	--primary-ink: #005f6d;
	--primary-soft: #e5f2f4;
	--accent: #fdba4d;
	--accent-soft: #fff3dd;
	--sand: #f3efe6;
	--mist: #eef1f4;
	--surface: #f5f5f4;
	--line: #e6e6e3;
	--bg: #ffffff;

	--font: "Geist", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	--fs: 1rem;
	--lh: 1.6;
	--ls: 0;
	--ws: 0;

	--r-sm: 10px;
	--r-md: 16px;
	--r-lg: 24px;
	--r-xl: 28px;
	--r-pill: 999px;

	--topbar: 60px;
	--rail: 248px;
	--rail-mini: 76px;
	--gutter: clamp(16px, 4vw, 40px);
	--content: 760px;
	--side: 300px;
	--shadow: 0 1px 2px rgba(18, 18, 18, .04), 0 8px 24px -12px rgba(18, 18, 18, .12);
	--ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--topbar) + 16px); }
body {
	margin: 0;
	background: var(--bg);
	color: var(--ink);
	font-family: var(--font);
	font-size: var(--fs);
	line-height: var(--lh);
	letter-spacing: var(--ls);
	word-spacing: var(--ws);
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
	font-feature-settings: "ss03" 1, "cv11" 1;
}
h1, h2, h3, h4 { color: var(--ink-strong); font-weight: 600; line-height: 1.15; letter-spacing: -0.015em; margin: 0; text-wrap: balance; }
p { margin: 0; }
a { color: var(--primary); text-decoration: none; text-underline-offset: .15em; }
a:hover { text-decoration: underline; }
img, svg, video { display: block; max-width: 100%; height: auto; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input, select { font: inherit; }
ol, ul { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 16px; top: -100px; z-index: 100; background: var(--ink-strong); color: #fff; padding: 10px 14px; border-radius: var(--r-sm); }
.skip:focus { top: 12px; }
.icon { width: 22px; height: 22px; flex: none; }
[hidden] { display: none !important; }

/* ---------- Topbar ---------- */
.topbar {
	position: sticky; top: 0; z-index: 40;
	display: grid; grid-template-columns: auto auto 1fr auto; align-items: center; gap: 12px;
	height: var(--topbar); padding: 0 var(--gutter);
	background: rgba(255, 255, 255, .92); backdrop-filter: saturate(160%) blur(12px); -webkit-backdrop-filter: saturate(160%) blur(12px);
	border-bottom: 1px solid var(--line);
	view-transition-name: topbar;
}
.iconbtn { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: var(--r-pill); color: var(--ink); }
.iconbtn:hover { background: var(--surface); }
.topbar__rail { display: none; }
.logo { display: inline-flex; align-items: center; color: var(--ink-strong); font-weight: 700; font-size: 1.35rem; letter-spacing: -0.03em; text-decoration: none !important; }
.logo__dot { color: var(--primary); }
.searchbtn {
	display: flex; align-items: center; gap: 10px; justify-self: center;
	width: min(100%, 520px); height: 40px; padding: 0 14px;
	color: var(--muted); background: var(--surface); border: 1px solid transparent; border-radius: var(--r-pill);
	transition: border-color .2s var(--ease), background .2s;
}
.searchbtn:hover { border-color: var(--line); background: #fff; }
.searchbtn__label { flex: 1; text-align: left; font-size: .95rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.searchbtn__kbd { font: 600 .7rem/1 var(--font); color: var(--faint); border: 1px solid var(--line); border-radius: 5px; padding: 3px 6px; background: #fff; }
.topbar__actions { display: flex; align-items: center; gap: 6px; position: relative; }
.topbar .topbar__cta { display: none; }

/* Reader prefs popover */
.reader { position: absolute; right: var(--gutter); top: calc(var(--topbar) - 6px); width: 280px; padding: 16px; background: #fff; border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--shadow); z-index: 50; }
.reader__title { font-weight: 600; margin-bottom: 8px; color: var(--ink-strong); }
.reader__row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.reader__hint { font-size: .8rem; color: var(--muted); margin-top: 8px; }
.switch { width: 44px; height: 26px; border-radius: var(--r-pill); background: var(--line); position: relative; transition: background .2s; }
.switch span { position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .2); transition: transform .2s var(--ease); }
.switch[aria-checked="true"] { background: var(--primary); }
.switch[aria-checked="true"] span { transform: translateX(18px); }

/* ---------- Shell: rail + main ---------- */
.shell { display: grid; grid-template-columns: minmax(0, 1fr); min-height: calc(100vh - var(--topbar)); }
.main { min-width: 0; padding: 0 var(--gutter) 64px; }

.rail {
	position: fixed; inset: 0 auto 0 0; z-index: 60; width: min(88vw, 320px);
	display: flex; flex-direction: column; gap: 8px;
	padding: 12px 12px 20px; background: #fff; border-right: 1px solid var(--line);
	transform: translateX(-100%); transition: transform .28s var(--ease); overflow-y: auto;
	view-transition-name: rail;
}
html[data-drawer="open"] .rail { transform: none; box-shadow: 0 0 0 100vmax rgba(18, 18, 18, .35); }
.scrim { position: fixed; inset: 0; z-index: 55; }
.rail__head { display: flex; align-items: center; justify-content: space-between; padding: 6px 8px 10px; }
.rail__group { display: flex; flex-direction: column; gap: 2px; padding: 6px 0; border-top: 1px solid var(--line); }
.rail__group:first-of-type { border-top: 0; }
.rail__label { font-size: .72rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); padding: 8px 12px 4px; }
.rail__item, .rail__menu a {
	display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px;
	border-radius: var(--r-sm); color: var(--ink); font-weight: 500; text-decoration: none !important; white-space: nowrap;
	transition: background .15s;
}
.rail__item:hover, .rail__menu a:hover { background: var(--surface); }
.rail__item[aria-current="page"], .rail__menu .current-menu-item > a { background: var(--primary-soft); color: var(--primary-ink); }
.rail__item .icon { color: var(--muted); }
.rail__item[aria-current="page"] .icon { color: var(--primary); }
.rail__foot { margin-top: auto; padding: 12px; display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: .82rem; }
.rail__foot a { color: var(--muted); }

@media (max-width: 1023px) {
	.topbar { grid-template-columns: auto auto 1fr auto; gap: 8px; }
	.searchbtn { width: 40px; height: 40px; padding: 0; justify-self: end; justify-content: center; background: none; }
	.searchbtn:hover { background: var(--surface); }
	.searchbtn__label, .searchbtn__kbd { display: none; }
	.topbar__actions { gap: 0; }
	.reader { right: 12px; }
}

/* Mobile tab bar */
.tabbar {
	position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
	display: grid; grid-template-columns: repeat(5, 1fr);
	padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
	background: rgba(255, 255, 255, .94); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
	border-top: 1px solid var(--line);
}
.tabbar a, .tabbar button { display: grid; justify-items: center; gap: 3px; padding: 6px 0; font-size: .68rem; font-weight: 500; color: var(--muted); text-decoration: none !important; border-radius: var(--r-sm); }
.tabbar [aria-current="page"] { color: var(--primary); }
.tabbar .icon { width: 24px; height: 24px; }
.main { padding-bottom: 96px; }

@media (min-width: 1024px) {
	.topbar { grid-template-columns: auto auto 1fr auto; }
	.topbar__rail { display: inline-grid; }
	.topbar__menu { display: none; }
	.topbar .topbar__cta { display: inline-flex; }
	.tabbar { display: none; }
	.main { padding-bottom: 64px; }

	.shell { grid-template-columns: var(--rail) minmax(0, 1fr); transition: grid-template-columns .28s var(--ease); }
	.rail {
		position: sticky; top: var(--topbar); height: calc(100vh - var(--topbar)); width: auto; inset: auto;
		transform: none; box-shadow: none; transition: none; padding-top: 16px;
	}
	.rail__head { display: none; }
	.scrim { display: none !important; }

	/* Mini rail: icons only. Default on reading pages, toggleable everywhere, persisted. */
	html[data-rail="mini"] .shell { grid-template-columns: var(--rail-mini) minmax(0, 1fr); }
	html[data-rail="mini"] .rail__item span, html[data-rail="mini"] .rail__label, html[data-rail="mini"] .rail__foot, html[data-rail="mini"] .rail__menu a span { display: none; }
	html[data-rail="mini"] .rail__item { justify-content: center; padding: 12px; }
}

/* ---------- Layout containers ---------- */
.wrap { display: grid; gap: 40px; max-width: 1180px; margin: 0 auto; padding-top: 28px; }
.wrap__main { min-width: 0; }
@media (min-width: 1180px) {
	.wrap--feed { grid-template-columns: minmax(0, 1fr) var(--side); }
}
.wrap--reading { max-width: var(--content); }

.intro { padding: 8px 0 28px; }
.intro__title { font-size: clamp(1.9rem, 4vw, 2.75rem); letter-spacing: -0.03em; }
.intro__lead { margin-top: 10px; font-size: 1.1rem; color: var(--muted); max-width: 60ch; }
.intro--archive .crumbs { margin-bottom: 12px; }
.intro--author { display: flex; gap: 20px; align-items: center; }
.intro__avatar { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips--sub { margin-top: 18px; }

/* ---------- Components ---------- */
.btn {
	display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 16px;
	border-radius: var(--r-pill); font-weight: 600; font-size: .95rem;
	color: var(--ink-strong); background: #fff; border: 1px solid var(--line); text-decoration: none !important;
	transition: transform .15s var(--ease), background .15s, border-color .15s;
}
.btn:hover { border-color: var(--ink-strong); }
.btn:active { transform: scale(.98); }
.btn--primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn--primary:hover { background: var(--primary-ink); border-color: var(--primary-ink); }
.btn--accent { background: var(--accent); border-color: var(--accent); color: var(--ink-strong); }

.chip {
	display: inline-flex; align-items: center; gap: 6px; min-height: 26px; padding: 0 10px;
	border-radius: var(--r-pill); font-size: .78rem; font-weight: 600; letter-spacing: .01em;
	color: var(--primary-ink); background: #fff; border: 1px solid var(--line); text-decoration: none !important; white-space: nowrap;
}
.chip:hover { border-color: var(--primary); }
.chip small { font-weight: 500; color: var(--faint); }
.chip--soft { background: var(--surface); border-color: transparent; color: var(--ink); }
.chip--soft:hover { background: var(--primary-soft); color: var(--primary-ink); }
.chip--pubblico { background: var(--primary-soft); border-color: transparent; }
.chip--privato { background: var(--accent-soft); border-color: transparent; color: #7a4a00; }
.chip--privato-convenzionato { background: var(--sand); border-color: transparent; color: #5a4a2a; }

.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: .82rem; color: var(--muted); }
.meta time, .meta span { white-space: nowrap; }
.more { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; font-size: .9rem; }
.more .icon { width: 18px; height: 18px; }

.crumbs { font-size: .82rem; color: var(--muted); }
.crumbs ol { display: flex; flex-wrap: wrap; gap: 4px 6px; }
.crumbs li + li::before { content: "›"; margin-right: 6px; color: var(--faint); }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--primary); }
.crumbs [aria-current] { color: var(--ink); font-weight: 500; }

/* Media box: 3.125:1 banner, rounded, tinted background for contain/fallback */
.media { position: relative; aspect-ratio: 25 / 8; overflow: hidden; border-radius: var(--r-lg); background: var(--surface); }
.media__img { width: 100%; height: 100%; object-fit: cover; }
.media--contain .media__img { object-fit: contain; padding: 8%; }
.media--tint-teal { background: var(--primary-soft); }
.media--tint-amber { background: var(--accent-soft); }
.media--tint-sand { background: var(--sand); }
.media--tint-mist { background: var(--mist); }
.media--type { display: grid; place-items: center; }
.media--type span { font-size: clamp(1.1rem, 2.6vw, 1.6rem); font-weight: 600; letter-spacing: -0.02em; color: var(--ink-strong); opacity: .75; }
.media--tint-teal.media--type span { color: var(--primary-ink); }

/* Cards */
.grid { display: grid; gap: 28px 24px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.card { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.card__media { display: block; border-radius: var(--r-lg); overflow: hidden; }
.card__media .media { transition: transform .35s var(--ease); }
.card:hover .card__media .media__img { transform: scale(1.03); transition: transform .5s var(--ease); }
.card__body { display: grid; gap: 8px; }
.card__title { font-size: 1.2rem; line-height: 1.25; }
.card__title a { color: inherit; }
.card__title a:hover { color: var(--primary); text-decoration: none; }
.card__excerpt { color: var(--muted); font-size: .95rem; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.card--compact { flex-direction: row; align-items: center; }
.card--compact .card__media { flex: none; width: 80px; }
.card--compact .media { aspect-ratio: 1; border-radius: var(--r-md); }

/* Hero card */
.card--hero { gap: 20px; margin-bottom: 44px; }
.card--hero .media { border-radius: var(--r-xl); }
.card--hero .card__title { font-size: clamp(1.6rem, 3.4vw, 2.4rem); letter-spacing: -0.025em; }
.card--hero .card__excerpt { font-size: 1.08rem; -webkit-line-clamp: 3; }
.card__author { font-size: .9rem; font-weight: 500; color: var(--ink); }
@media (min-width: 720px) {
	.card--hero .card__body { grid-template-columns: 1fr; max-width: 62ch; }
}

.feed__head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin: 0 0 20px; }
.feed__head h2 { font-size: 1.35rem; }
.feed + .feed { margin-top: 48px; }

/* Side column */
.side { display: grid; gap: 20px; align-content: start; }
.side__box { padding: 20px; border: 1px solid var(--line); border-radius: var(--r-lg); background: #fff; }
.side__box--tint { background: var(--primary-soft); border-color: transparent; }
.side__box--tint p { color: var(--primary-ink); }
.side__box .btn { margin-top: 12px; }
.side__h { font-size: 1rem; font-weight: 600; color: var(--ink-strong); margin-bottom: 12px; }
.list--n { display: grid; gap: 12px; }
.li { display: flex; gap: 12px; align-items: flex-start; }
.li__n { font-size: 1.1rem; font-weight: 700; color: var(--line); line-height: 1.3; min-width: 1.6em; letter-spacing: -0.02em; }
.li__title { display: block; color: var(--ink-strong); font-weight: 500; line-height: 1.3; }
.li__meta { font-size: .78rem; color: var(--faint); }

/* Pagination */
.pagination { margin-top: 40px; }
.pagination .nav-links { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; }
.page-numbers { display: inline-grid; place-items: center; min-width: 40px; height: 40px; padding: 0 8px; border-radius: var(--r-pill); border: 1px solid var(--line); font-weight: 500; color: var(--ink); text-decoration: none !important; }
.page-numbers.current { background: var(--ink-strong); color: #fff; border-color: var(--ink-strong); }
.page-numbers.dots { border: 0; }
.empty { color: var(--muted); padding: 40px 0; }

/* ---------- Article ---------- */
.post { max-width: 1120px; margin: 0 auto; padding-top: 24px; }
.post__head { max-width: var(--content); display: grid; gap: 16px; padding-bottom: 28px; }
.post__title { font-size: clamp(1.9rem, 4.2vw, 2.9rem); letter-spacing: -0.03em; line-height: 1.1; }
.post__lead { font-size: 1.2rem; line-height: 1.5; color: var(--muted); text-wrap: pretty; }
.byline { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: .9rem; color: var(--muted); }
.byline__author { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-strong); font-weight: 500; }
.byline__avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.byline__sep { color: var(--faint); }
.byline__upd { color: var(--primary-ink); }
.post__banner { margin: 0 0 32px; max-width: var(--content); }
.post__banner .media { border-radius: var(--r-xl); }
.post__grid { display: grid; gap: 40px; align-items: start; }
.post__aside { display: none; }
@media (min-width: 1100px) {
	.post__grid { grid-template-columns: minmax(0, var(--content)) var(--side); }
	.post__grid--wide { grid-template-columns: minmax(0, var(--content)); }
	.post__aside { display: block; }
	.sticky { position: sticky; top: calc(var(--topbar) + 24px); display: grid; gap: 16px; }
}

.toc { padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--r-lg); max-height: calc(100vh - var(--topbar) - 200px); overflow: auto; }
.toc__title { font-size: .78rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); margin-bottom: 10px; }
.toc ol { display: grid; gap: 2px; counter-reset: toc; }
.toc a { display: block; padding: 6px 10px; border-radius: var(--r-sm); color: var(--muted); font-size: .9rem; line-height: 1.35; border-left: 2px solid transparent; }
.toc a:hover { color: var(--ink-strong); text-decoration: none; background: var(--surface); }
.toc a[aria-current="true"] { color: var(--primary-ink); border-left-color: var(--primary); background: var(--primary-soft); }
.toc__l3 a { padding-left: 22px; font-size: .84rem; }

/* Entry typography */
.entry { min-width: 0; font-size: 1.125rem; line-height: 1.7; }
.entry > * + * { margin-top: 1.25em; }
.entry > h2 { font-size: 1.65rem; margin-top: 2.2em; letter-spacing: -0.02em; }
.entry > h3 { font-size: 1.3rem; margin-top: 1.8em; }
.entry > h4 { font-size: 1.1rem; margin-top: 1.5em; }
.entry h2 + *, .entry h3 + *, .entry h4 + * { margin-top: .6em; }
.entry a { text-decoration: underline; text-decoration-color: rgba(0, 127, 145, .35); text-decoration-thickness: 1.5px; }
.entry a:hover { text-decoration-color: currentColor; }
.entry strong, .entry b { font-weight: 600; color: var(--ink-strong); }
.entry ul, .entry ol { padding-left: 1.4em; display: grid; gap: .45em; }
.entry ul { list-style: disc; }
.entry ol { list-style: decimal; }
.entry li::marker { color: var(--primary); }
.entry blockquote { margin: 1.6em 0; padding: 4px 0 4px 20px; border-left: 3px solid var(--accent); color: var(--ink-strong); font-size: 1.15em; }
.entry hr { border: 0; border-top: 1px solid var(--line); margin: 2.4em 0; }
.entry img { border-radius: var(--r-md); }
.entry figure { margin: 1.6em 0; }
.entry figcaption, .entry .wp-caption-text { font-size: .85rem; color: var(--muted); margin-top: 8px; }
.entry .wp-caption { max-width: 100%; }
.entry .alignleft { float: left; margin: .4em 1.4em 1em 0; max-width: 45%; }
.entry .alignright { float: right; margin: .4em 0 1em 1.4em; max-width: 45%; }
.entry .aligncenter { margin-inline: auto; }
.entry table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.entry th, .entry td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.entry th { color: var(--ink-strong); font-weight: 600; background: var(--surface); }
.table-wrap { overflow-x: auto; }
.entry iframe { max-width: 100%; }
.embed { aspect-ratio: 16 / 9; }
.embed iframe { width: 100%; height: 100%; border: 0; border-radius: var(--r-md); }
.subheading { color: var(--muted); margin-top: .3em !important; }
.dropcap { float: left; font-size: 3.4em; line-height: .85; font-weight: 600; color: var(--primary); margin: .06em .12em 0 0; }
.box { padding: 20px 22px; background: var(--surface); border-radius: var(--r-md); font-size: .98em; }
.box .box { padding: 0; background: none; border-radius: 0; }
.box .box + .box { margin-top: 1em; }
.box__title { font-weight: 600; color: var(--ink-strong); margin-bottom: .5em; }
.box > * + * { margin-top: .8em; }
.box ul, .box ol { gap: .3em; }
.box--note { background: var(--accent-soft); }
.col + .col { margin-top: 1em; }
.iconlist li { padding-left: 0; list-style: none; position: relative; padding-left: 1.4em; }
.iconlist li::before { content: ""; position: absolute; left: 0; top: .62em; width: .55em; height: .55em; border-radius: 50%; background: var(--primary); }
details.toggle { border: 1px solid var(--line); border-radius: var(--r-md); padding: 12px 16px; }
details.toggle summary { font-weight: 600; cursor: pointer; color: var(--ink-strong); }
details.toggle[open] summary { margin-bottom: .6em; }
.wp-block-image img, .wp-block-embed { border-radius: var(--r-md); }
.wp-block-quote { border-left: 3px solid var(--accent); padding-left: 20px; }
.wp-block-table table { width: 100%; }

.post__foot { margin-top: 48px; padding-top: 28px; border-top: 1px solid var(--line); display: grid; gap: 24px; }
.authorbox { display: flex; gap: 16px; align-items: flex-start; padding: 20px; border-radius: var(--r-lg); background: var(--surface); }
.authorbox__avatar { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; flex: none; }
.authorbox__name { font-weight: 600; }
.authorbox__name a { color: var(--ink-strong); }
.authorbox__bio { font-size: .92rem; color: var(--muted); margin-top: 4px; }
.disclaimer { font-size: .82rem; color: var(--faint); }
.related { margin-top: 64px; padding-top: 32px; border-top: 1px solid var(--line); }

/* ---------- Centri ---------- */
.regions { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.regions__item { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r-md); color: var(--ink-strong); font-weight: 500; text-decoration: none !important; transition: border-color .15s, background .15s; }
.regions__item:hover { border-color: var(--primary); background: var(--primary-soft); }
.regions__item small { color: var(--faint); font-weight: 500; }
.centri { margin-top: 28px; }
.centri__h { font-size: 1.15rem; padding-bottom: 10px; margin-bottom: 4px; border-bottom: 1px solid var(--line); position: sticky; top: var(--topbar); background: #fff; z-index: 1; }
.centri__list { display: grid; }
.centro { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.centro__title { color: var(--ink-strong); font-weight: 500; }
.centro__sub { font-size: .85rem; color: var(--muted); margin-top: 2px; }
.centro__side { display: flex; align-items: center; gap: 12px; flex: none; }
.centro__tel { display: inline-flex; align-items: center; gap: 6px; font-size: .88rem; font-weight: 500; color: var(--ink); white-space: nowrap; }
.centro__tel .icon { width: 16px; height: 16px; color: var(--primary); }
@media (max-width: 640px) { .centro { flex-direction: column; align-items: flex-start; gap: 8px; } }
.facts { display: grid; gap: 14px; padding: 20px; border-radius: var(--r-lg); background: var(--surface); margin: 0 0 1.5em; font-size: 1rem; }
.facts dt { font-size: .75rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); }
.facts dd { margin: 2px 0 0; color: var(--ink-strong); }
.facts .more { margin-left: 8px; }

/* ---------- Search overlay ---------- */
.search { position: fixed; inset: 0; z-index: 70; background: rgba(18, 18, 18, .4); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); display: grid; align-items: start; justify-items: center; padding: 8vh 16px; overflow-y: auto; }
.search__panel { width: min(100%, 680px); background: #fff; border-radius: var(--r-lg); box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .35); overflow: hidden; }
.search__form { display: flex; align-items: center; gap: 12px; padding: 8px 12px 8px 18px; border-bottom: 1px solid var(--line); color: var(--muted); }
.search__form--inline { border: 1px solid var(--line); border-radius: var(--r-pill); }
.search__input { flex: 1; min-width: 0; height: 48px; border: 0; outline: 0; font-size: 1.1rem; color: var(--ink-strong); background: transparent; }
.search__results:empty { display: none; }
.search__results { max-height: 60vh; overflow-y: auto; padding: 8px; }
.search__group { padding: 10px 12px 4px; font-size: .72rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); }
.search__item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border-radius: var(--r-sm); color: var(--ink-strong); text-decoration: none !important; }
.search__item:hover, .search__item:focus { background: var(--primary-soft); color: var(--primary-ink); outline: 0; }
.search__item small { color: var(--faint); white-space: nowrap; }
.search__all { display: block; padding: 12px; text-align: center; font-weight: 600; }
.search__status { padding: 16px; color: var(--muted); font-size: .95rem; }
.search__hints { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 14px 18px; font-size: .85rem; color: var(--muted); background: var(--surface); }
.search__hints a { padding: 4px 10px; border-radius: var(--r-pill); background: #fff; border: 1px solid var(--line); color: var(--ink); }
body[data-lock] { overflow: hidden; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line); background: var(--surface); }
.footer__inner { max-width: 1180px; margin: 0 auto; padding: 48px var(--gutter) 32px; display: grid; gap: 32px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.footer__brand p { margin-top: 12px; color: var(--muted); font-size: .92rem; max-width: 34ch; }
.footer__h { font-weight: 600; color: var(--ink-strong); margin-bottom: 12px; }
.footer__col ul { display: grid; gap: 8px; }
.footer__col a { color: var(--muted); }
.footer__col a:hover { color: var(--primary); }
.footer__col p { color: var(--muted); font-size: .92rem; margin-bottom: 12px; }
.footer__legal { max-width: 1180px; margin: 0 auto; padding: 16px var(--gutter) 24px; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: .82rem; color: var(--faint); border-top: 1px solid var(--line); }
.footer__legal ul { display: flex; flex-wrap: wrap; gap: 16px; }
.footer__legal a { color: var(--muted); }
@media (max-width: 1023px) { .footer { padding-bottom: 72px; } }

/* ---------- Reading modes (persisted per device) ---------- */
html[data-text="lg"] { --fs: 1.15rem; }
html[data-text="lg"] .entry { font-size: 1.32rem; line-height: 1.75; }
html[data-spacing="wide"] { --lh: 1.85; --ls: .02em; --ws: .1em; }
html[data-spacing="wide"] .entry { line-height: 1.95; }
html[data-spacing="wide"] .entry p { max-width: 62ch; }
html[data-contrast="high"] { --ink: #000; --ink-strong: #000; --muted: #333; --faint: #555; --line: #9a9a9a; --primary: #005f6d; --primary-ink: #004a55; }
html[data-contrast="high"] .entry a, html[data-contrast="high"] .card__title a { text-decoration: underline; }
html[data-contrast="high"] .topbar, html[data-contrast="high"] .tabbar { background: #fff; }

/* ---------- Cross-document view transitions (app feel, zero JS) ---------- */
@view-transition { navigation: auto; }
@media (prefers-reduced-motion: no-preference) {
	::view-transition-old(root) { animation: 160ms var(--ease) both fade-out; }
	::view-transition-new(root) { animation: 220ms var(--ease) both fade-in; }
	::view-transition-group(topbar), ::view-transition-group(rail) { animation-duration: 0s; }
}
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
	.rail, .card__media .media, .switch span { transition: none !important; }
}
@keyframes fade-in { from { opacity: 0; } }
@keyframes fade-out { to { opacity: 0; } }

/* ---------- Print ---------- */
@media print {
	.topbar, .rail, .tabbar, .footer, .post__aside, .related, .search, .side { display: none !important; }
	.shell { display: block; }
	body { font-size: 11pt; }
	.entry a::after { content: " (" attr(href) ")"; font-size: .8em; color: #555; }
}
