/*
 * Humanitas Pronto Soccorso — front end + editor canvas.
 *
 * Ported from the brief (Humanitas_ProntoSoccorso_Minisito_con_Guida-v2-def).
 * Class names are the brief's own, so this file reads side by side with it.
 * What changed in the port, and why:
 *  - colours, radii and shadows read the theme.json presets (no literals);
 *  - the brief's markup became blocks, so a few selectors follow the block
 *    markup (paragraph wrappers, core/button, core/details) — each is marked;
 *  - left/right became logical properties, so Arabic (RTL) mirrors for free;
 *  - the brief's 100vw full-bleed hack is replaced by the blocks' align:full.
 */

/* ---------- Tokens (brief names → theme.json presets) ---------- */
:root {
	--teal-900: var(--wp--preset--color--teal-900);
	--teal-800: var(--wp--preset--color--teal-800);
	--teal-700: var(--wp--preset--color--teal-700);
	--teal-600: var(--wp--preset--color--teal-600);
	--teal-500: var(--wp--preset--color--teal-500);
	--teal-300: var(--wp--preset--color--teal-300);
	--mint-100: var(--wp--preset--color--mint-100);
	--mint-50: var(--wp--preset--color--mint-50);
	--paper: var(--wp--preset--color--paper);
	--ink: var(--wp--preset--color--ink);
	--ink-soft: var(--wp--preset--color--ink-soft);
	--ink-faint: var(--wp--preset--color--ink-faint);
	--gold-700: var(--wp--preset--color--gold-700);
	--gold-100: var(--wp--preset--color--gold-100);
	--red: var(--wp--preset--color--code-red);
	--orange: var(--wp--preset--color--code-orange);
	--blue: var(--wp--preset--color--code-blue);
	--green: var(--wp--preset--color--code-green);
	--grey: var(--wp--preset--color--code-white);
	--grey-100: var(--wp--preset--color--grey-100);
	--line: var(--wp--preset--color--line);
	--rosa: var(--wp--preset--color--rosa);
	--plum-700: var(--teal-900);
	--plum-100: var(--mint-100);
	--radius-s: var(--wp--custom--radius--s);
	--radius-m: var(--wp--custom--radius--m);
	--radius-pill: var(--wp--custom--radius--pill);
	--shadow: var(--wp--preset--shadow--md);
	--shadow-sm: var(--wp--preset--shadow--sm);
	--shadow-card: var(--wp--preset--shadow--card);
	--shadow-card-rosa: var(--wp--preset--shadow--card-rosa);
	/* Brand guide: Century Old Style → Source Serif 4 (reading text),
	   Gotham → Montserrat (titles, labels, UI). Arabic overrides both below. */
	--ps-serif: var(--wp--preset--font-family--serif);
	--ps-sans: var(--wp--preset--font-family--sans);
	--ps-topbar-h: 66px;
}
:lang(ar) {
	--ps-serif: 'Noto Sans Arabic', Tahoma, sans-serif;
	--ps-sans: 'Noto Sans Arabic', Tahoma, sans-serif;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
	margin: 0;
	font-family: var(--ps-serif);
	color: var(--ink);
	background: var(--paper);
	-webkit-font-smoothing: antialiased;
}
h1, h2, h3, .display {
	font-family: var(--ps-sans);
	font-weight: 600;
	line-height: 1.15;
	margin: 0;
	color: var(--teal-900);
}
p { margin: 0; }
a { color: inherit; }
button { font-family: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--teal-700); outline-offset: 2px; }
.visually-hidden, .screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap;
}
.ps-svg { display: inline-block; flex: none; }
/* Directional icons point the other way in RTL. */
[dir="rtl"] .ps-flip, [dir="rtl"] .ps-svg--arrow-right, [dir="rtl"] .ps-svg--arrow-left { transform: scaleX(-1); }

.ps-skip {
	position: absolute; inset-inline-start: 12px; top: -60px; z-index: 100;
	background: var(--teal-900); color: #fff; padding: 10px 16px; border-radius: var(--radius-s);
	font-family: var(--ps-sans); font-weight: 600; font-size: 14px; text-decoration: none;
}
.ps-skip:focus { top: 12px; }

/* ---------- Top bar ---------- */
.topbar { position: sticky; top: 0; z-index: 50; background: var(--teal-800); }
.admin-bar .topbar { top: 32px; }
@media (max-width: 782px) { .admin-bar .topbar { top: 46px; } }
@media (max-width: 600px) { .admin-bar .topbar { top: 0; } }
.topbar-inner {
	max-width: var(--wp--custom--container); margin: 0 auto; padding: 16px var(--wp--custom--gutter);
	display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-mark {
	width: 34px; height: 34px; border-radius: 9px; background: #fff;
	display: flex; align-items: center; justify-content: center; flex: none;
	color: var(--teal-800); font-family: 'Source Serif 4', serif; font-weight: 700; font-size: 18px;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.2; text-align: start; }
.brand-text strong { font-family: 'Source Serif 4', serif; font-size: 16px; font-weight: 700; letter-spacing: .03em; color: #fff; }
.brand-text span { font-size: 11.5px; color: rgba(255, 255, 255, .8); }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.topbar-tag {
	font-size: 13px; font-weight: 600; color: var(--teal-800); background: #fff;
	padding: 8px 18px; border-radius: var(--radius-pill);
	white-space: nowrap; text-decoration: none; font-family: var(--ps-sans);
	transition: transform .12s ease;
}
.topbar-tag:hover { transform: translateY(-1px); }

/* Language switcher (not in the brief: needed for the four languages). */
.ps-lang { position: relative; }
.ps-lang__toggle {
	list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px;
	color: #fff; border: 1px solid rgba(255, 255, 255, .45); border-radius: var(--radius-pill);
	padding: 7px 12px; font-family: var(--ps-sans); font-weight: 600; font-size: 13px; min-height: 36px;
}
.ps-lang__toggle::-webkit-details-marker { display: none; }
.ps-lang__toggle:hover, .ps-lang[open] .ps-lang__toggle { background: rgba(255, 255, 255, .12); }
.ps-lang__toggle .ps-svg { width: 16px; height: 16px; }
.ps-lang__toggle .ps-lang__chev { width: 14px; height: 14px; transition: transform .15s ease; }
.ps-lang[open] .ps-lang__chev { transform: rotate(180deg); }
.ps-lang__list {
	position: absolute; inset-inline-end: 0; top: calc(100% + 8px); z-index: 60;
	min-width: 190px; margin: 0; padding: 6px; list-style: none;
	background: #fff; border: 1px solid var(--line); border-radius: var(--radius-s); box-shadow: var(--shadow);
}
.ps-lang__item {
	display: block; padding: 10px 12px; border-radius: 8px; text-decoration: none;
	font-family: var(--ps-sans); font-size: 14px; font-weight: 500; color: var(--teal-900);
}
.ps-lang__item:lang(ar) { font-family: 'Noto Sans Arabic', sans-serif; }
a.ps-lang__item:hover, a.ps-lang__item:focus-visible { background: var(--mint-100); }
.ps-lang__item.is-current { color: var(--teal-800); font-weight: 700; background: var(--mint-50); }

/* ---------- Page shell ---------- */
.ps-is-detail .ps-content { padding-bottom: 80px; }
.ps-footer__inner {
	max-width: var(--wp--style--global--content-size); margin: 40px auto 0;
	border-top: 1px solid var(--line); padding: 26px 0 60px;
	color: var(--ink-faint); font-size: 12.5px; font-family: var(--ps-sans);
}
.ps-footer { padding-inline: var(--wp--custom--gutter); }

/* core/buttons wrapper (markup from the block, styles from the brief) */
.ps-btns { display: flex; flex-wrap: wrap; gap: 10px; }
.wp-block-button.has-arrow .wp-block-button__link::after {
	content: ""; width: 16px; height: 16px; flex: none; background: currentColor;
	-webkit-mask: var(--ps-ico-arrow) center / contain no-repeat; mask: var(--ps-ico-arrow) center / contain no-repeat;
}
[dir="rtl"] .wp-block-button.has-arrow .wp-block-button__link::after { transform: scaleX(-1); }
:root { --ps-ico-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M12 5l7 7-7 7'/%3E%3C/svg%3E"); }

/* ---------- Home: hero ---------- */
.hero-v3 { display: grid; grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: center; padding-top: 36px; }
.hero-v3-content h1 {
	font-family: var(--ps-serif); font-weight: 700; color: var(--ink);
	font-size: clamp(32px, 4.6vw, 50px); line-height: 1.1;
}
.hero-v3-lede { margin-top: 18px; font-size: 16.5px; line-height: 1.6; color: var(--ink-faint); max-width: 34ch; }
.wp-block-button.hero-cta { margin-top: 28px; } /* beats core .wp-block-buttons > .wp-block-button { margin: 0 } */
.hero-cta .wp-block-button__link {
	display: inline-flex; align-items: center; gap: 8px;
	background: var(--teal-800); color: #fff; border-radius: var(--radius-s);
	padding: 13px 22px; font-family: var(--ps-sans); font-weight: 600; font-size: 14px; text-decoration: none;
}
.hero-v3-illustration {
	aspect-ratio: 5 / 3; border-radius: var(--radius-m); background: var(--mint-100);
	display: flex; align-items: center; justify-content: center; padding: 24px; text-align: center;
}
.hero-v3-illustration span { color: var(--teal-600); font-size: 13px; opacity: .85; }
.hero-v3-illustration img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--radius-m); }

/* ---------- Home: "Il tuo tempo è importante" band ---------- */
.band {
	background: linear-gradient(135deg, var(--teal-800) 0%, var(--teal-600) 100%);
	margin-top: 36px; padding-block: 22px; color: #fff;
}
.band-inner { display: flex; align-items: center; gap: 24px; }
.band-icon {
	width: 48px; height: 48px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .3);
	display: flex; align-items: center; justify-content: center; flex: none;
}
.band-icon svg { width: 22px; height: 22px; }
.band-text { flex: 1; }
.band h2 { color: #fff; font-size: 18px; }
.band p { margin-top: 6px; font-size: 13.5px; line-height: 1.55; color: rgba(255, 255, 255, .9); max-width: none; }

/* ---------- Section heads ---------- */
.section-head { margin-top: 56px; margin-bottom: 18px; }
.section-head h2 { font-size: 22px; }
.section-head p { color: var(--ink-faint); font-size: 14.5px; line-height: 1.6; margin-top: 6px; max-width: none; }

/* ---------- Full-bleed colour bands ---------- */
.full-bleed { padding-block: 52px; margin-top: 56px; margin-bottom: 0; }
.full-bleed .section-head { margin-top: 0; }
.full-bleed-mint { background: var(--mint-100); }
.full-bleed-dark { background: linear-gradient(135deg, var(--teal-900) 0%, var(--teal-800) 100%); }
.full-bleed-dark .section-head h2, .full-bleed-dark .menu-header h2 { color: #fff; }
.full-bleed-dark .section-head p, .full-bleed-dark .menu-header p { color: rgba(255, 255, 255, .72); }
.full-bleed-dark .menu-header { margin-top: 0; }
#guida { scroll-margin-top: var(--ps-topbar-h); }

/* ---------- Guide grid (hit-ps/guide-grid) ---------- */
.menu-header { margin-top: 64px; }
.menu-header h2 { font-size: 26px; }
.menu-header p { color: var(--ink-faint); font-size: 14.5px; line-height: 1.6; margin-top: 8px; max-width: none; }
.menu-grid { margin-top: 26px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; padding-bottom: 70px; }
.full-bleed .menu-grid { padding-bottom: 0; }
.menu-card {
	display: flex; gap: 16px; align-items: flex-start; text-decoration: none; color: inherit;
	text-align: start; border: 1px solid var(--line); background: var(--paper);
	border-radius: var(--radius-s); padding: 20px; transition: border-color .15s ease, box-shadow .15s ease;
}
.menu-card:hover, .menu-card:focus-visible { border-color: var(--teal-500); box-shadow: var(--shadow-sm); }
.menu-card .num { font-family: var(--ps-serif); font-size: 22px; color: var(--teal-500); font-weight: 600; min-width: 30px; }
.menu-card .body strong { display: block; font-family: var(--ps-sans); font-size: 16px; color: var(--teal-900); margin-bottom: 4px; }
.menu-card .body .desc { display: block; font-size: 13.5px; color: var(--ink-soft); line-height: 1.5; }
.menu-card .arrow { margin-inline-start: auto; color: var(--teal-500); flex: none; width: 18px; height: 18px; margin-top: 4px; }
.menu-card--rosa { background: linear-gradient(135deg, #FFF6F8 0%, #FCE4EC 100%); border-color: #F3C6D6; }
.menu-card--rosa:hover, .menu-card--rosa:focus-visible { border-color: #E88AA8; box-shadow: var(--shadow-sm); }
.menu-card--rosa .num, .menu-card--rosa .arrow { color: var(--rosa); }

/* ---------- Triage codes ---------- */
.code-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin: 18px 0 8px; }
.code-card { border-radius: var(--radius-m); padding: 18px 12px; text-align: center; color: #fff; }
.code-card .code-name {
	font-family: var(--ps-sans); font-weight: 700; font-size: 10.5px;
	letter-spacing: .07em; text-transform: uppercase; opacity: .85;
}
.code-card .code-time { font-family: var(--ps-sans); font-size: 19px; font-weight: 700; margin: 8px 0 2px; }
.code-card .code-time span { font-size: 10px; font-weight: 500; display: block; opacity: .85; text-transform: none; letter-spacing: 0; }
.code-card .code-label { font-family: var(--ps-sans); font-size: 10.5px; font-weight: 600; opacity: .95; margin-top: 2px; }
.code-card p:not(.code-name, .code-time, .code-label) { font-size: 10.5px; line-height: 1.4; margin-top: 9px; color: rgba(255, 255, 255, .88); } /* block port: only the description (WP adds .wp-block-paragraph to every p) */
.code-rosso { background: var(--red); }
.code-arancione { background: var(--orange); }
.code-azzurro { background: var(--blue); }
.code-verde { background: var(--green); }
.code-bianco { background: var(--grey); }

.notice-box { display: flex; gap: 12px; background: var(--gold-100); border-radius: var(--radius-s); padding: 16px 18px; margin-top: 6px; }
.notice-box svg { width: 18px; height: 18px; color: var(--gold-700); flex: none; margin-top: 2px; }
.notice-box p { font-size: 13.8px; color: #3B453F; line-height: 1.55; }

/* ---------- Cards ---------- */
.card-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 8px; }
.info-card {
	border: 1.5px solid var(--teal-500); border-radius: var(--radius-s); padding: 20px 18px;
	background: #fff; box-shadow: var(--shadow-card);
}
.info-card .icn { width: 23px; height: 23px; color: var(--teal-700); margin-bottom: 10px; }
.info-card svg:not(.icn) { width: 23px; height: 23px; color: var(--teal-700); margin-bottom: 10px; }
.info-card strong { display: block; font-family: var(--ps-sans); font-size: 14.5px; color: var(--teal-900); margin-bottom: 5px; }
.info-card p { font-size: 13.5px; color: var(--ink-soft); line-height: 1.55; }
.info-card.pink { border-color: #F3C6D6; box-shadow: var(--shadow-card-rosa); }
.info-card.pink svg { color: var(--rosa); }
.info-card.pink strong { color: #B44873; }
.detail-header .num.pink { background: var(--rosa); }
.badge-wip {
	display: inline-block; margin-top: 8px; font-family: var(--ps-sans); font-size: 11px; font-weight: 600; color: var(--gold-700);
	background: var(--gold-100); padding: 3px 9px; border-radius: var(--radius-pill);
}
.info-card p.badge-wip, .now-card p.badge-wip { font-size: 11px; line-height: 1.5; color: var(--gold-700); }

.contact-card {
	display: flex; gap: 14px; align-items: flex-start; background: var(--mint-100); border: 1px solid var(--teal-300);
	border-radius: var(--radius-s); padding: 18px; margin-top: 8px;
}
.contact-card .icn, .contact-card > svg { width: 24px; height: 24px; color: var(--plum-700); flex: none; }
.contact-card strong { display: block; font-family: var(--ps-sans); color: var(--plum-700); font-size: 15px; margin-bottom: 4px; }
.contact-card p { font-size: 13.5px; color: #1F4A3A; line-height: 1.55; }

/* people-card: staff/support contact (infermiere di comunicazione) */
.people-card {
	display: flex; gap: 16px; align-items: flex-start; background: var(--mint-100);
	border: 1px solid var(--teal-300); border-radius: var(--radius-m); padding: 20px; margin-top: 14px;
}
.people-avatar {
	width: 56px; height: 56px; border-radius: 50%; background: var(--teal-800); color: #fff;
	display: flex; align-items: center; justify-content: center; flex: none;
}
.people-avatar svg { width: 26px; height: 26px; }
.people-role {
	display: inline-block; background: #fff; color: var(--teal-800); font-family: var(--ps-sans); font-size: 11px; font-weight: 700;
	letter-spacing: .03em; padding: 3px 10px; border-radius: var(--radius-pill); margin-bottom: 8px;
}
.people-body strong { font-family: var(--ps-sans); display: block; font-size: 16px; color: var(--teal-900); margin-bottom: 5px; }
.people-body p:not(.people-role) { font-size: 13.5px; color: var(--ink-soft); line-height: 1.55; }
.people-meta { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.meta-chip {
	display: inline-flex; align-items: center; gap: 6px; background: #fff; border: 1px solid var(--line);
	color: var(--teal-800); font-family: var(--ps-sans); font-weight: 600; font-size: 12.5px;
	padding: 6px 11px; border-radius: var(--radius-pill);
}
.meta-chip svg { width: 14px; height: 14px; flex: none; }
.meta-chip p, .now-card .meta-chip p { font-size: 12.5px; line-height: 1.4; color: var(--teal-800); }
.meta-chip a { color: inherit; }

.wip-note { display: flex; gap: 12px; background: var(--grey-100); border-radius: var(--radius-s); padding: 14px 16px; margin-top: 22px; }
.wip-note svg { width: 17px; height: 17px; color: var(--ink-faint); flex: none; margin-top: 2px; }
.wip-note p { font-size: 13px; color: var(--ink-faint); line-height: 1.5; font-style: italic; }

/* ---------- Dove trovo cosa ---------- */
.where-list { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 4px; }
.where-item {
	display: flex; align-items: center; gap: 12px; border: 1px solid var(--line);
	border-radius: var(--radius-s); padding: 12px 16px; background: var(--paper);
}
.where-item svg { width: 18px; height: 18px; color: var(--teal-700); flex: none; }
.where-item span, .where-item p { font-size: 13.8px; color: var(--ink); line-height: 1.4; }
.tbc { color: var(--gold-700); font-style: italic; }

/* ---------- CTA boxes (Salutile / non è un'emergenza / 1522) ---------- */
.cta-box { display: flex; align-items: center; gap: 20px; border-radius: var(--radius-m); padding: 24px 26px; margin-top: 20px; flex-wrap: wrap; }
.cta-box.cta-info { background: var(--mint-100); border: 1px solid var(--teal-300); }
.cta-box.cta-alert { background: #FBEAEA; border: 1px solid #E7B9BC; }
.cta-box .cta-icon { width: 46px; height: 46px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex: none; }
.cta-icon svg { width: 24px; height: 24px; }
.cta-info .cta-icon { background: var(--teal-800); color: #fff; }
.cta-alert .cta-icon { background: var(--red); color: #fff; }
.cta-box .cta-body { flex: 1; min-width: 240px; }
.cta-box .cta-body strong { display: block; font-family: var(--ps-sans); font-size: 16px; color: var(--teal-900); margin-bottom: 4px; }
.cta-alert .cta-body strong { color: var(--red); }
.cta-box .cta-body p { font-size: 13.5px; color: var(--ink-soft); line-height: 1.55; }
.cta-btn .wp-block-button__link {
	display: inline-flex; align-items: center; gap: 8px; border: none; border-radius: var(--radius-s);
	padding: 11px 20px; font-family: var(--ps-sans); font-weight: 600; font-size: 13.5px;
	text-decoration: none; white-space: nowrap;
}
.cta-btn.has-arrow .wp-block-button__link::after { width: 15px; height: 15px; }
.cta-info .cta-btn .wp-block-button__link { background: var(--teal-800); color: #fff; }
.cta-alert .cta-btn .wp-block-button__link { background: var(--red); color: #fff; }

/* ============================================================
   DETAIL PAGES
   ============================================================ */
.detail { padding-top: 28px; }
.back-btn {
	display: inline-flex; align-items: center; gap: 8px; text-decoration: none;
	color: var(--teal-700); font-family: var(--ps-sans); font-size: 14px; font-weight: 600;
	padding: 8px 0; margin-bottom: 22px;
}
.back-btn svg { width: 16px; height: 16px; }
.back-btn:hover { color: var(--teal-900); }
.detail-header {
	display: flex; align-items: flex-start; gap: 18px;
	padding-bottom: 26px; border-bottom: 1px solid var(--line); margin-bottom: 34px;
}
.detail-header .num {
	font-family: var(--ps-serif); font-size: 20px; font-weight: 600; color: #fff;
	background: var(--teal-800); width: 46px; height: 46px; border-radius: 12px;
	display: flex; align-items: center; justify-content: center; flex: none;
}
.detail-header h1 { font-size: 30px; }
.detail-header .detail-sub { margin-top: 6px; color: var(--ink-faint); font-size: 15px; }

.detail-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 48px; align-items: start; }
.detail-main > section { margin-bottom: 38px; }
.detail-main > section:last-child { margin-bottom: 0; }
.detail-main h3 { font-size: 18px; margin-bottom: 12px; color: var(--teal-900); }
.detail-main p { color: var(--ink-soft); line-height: 1.7; font-size: 15px; }
.detail-main p + p { margin-top: 10px; }

.list-plain { margin: 0; padding: 0; list-style: none; }
.list-plain li { position: relative; padding-inline-start: 20px; color: var(--ink-soft); font-size: 15px; line-height: 1.7; margin-bottom: 8px; }
.list-plain li::before { content: ""; position: absolute; inset-inline-start: 0; top: 11px; width: 6px; height: 6px; border-radius: 50%; background: var(--teal-500); }
.list-plain li strong { color: var(--teal-900); }

/* ---------- Journey bar (hit-ps/journey) ---------- */
.journey {
	margin: 0 0 30px; padding: 14px 18px;
	background: var(--mint-100); border: 1px solid var(--teal-300); border-radius: var(--radius-m);
}
.journey-track {
	display: flex; align-items: center; gap: 0; margin: 0; padding: 0; list-style: none;
	overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
.journey-track::-webkit-scrollbar { display: none; }
.journey-item { display: flex; align-items: center; flex: none; }
.journey-step {
	display: flex; align-items: center; gap: 9px; flex: none; text-decoration: none; color: inherit;
	border: none; background: none; padding: 6px 2px; min-height: 40px; border-radius: var(--radius-s);
}
.journey-dot {
	width: 26px; height: 26px; border-radius: 50%; flex: none;
	background: #fff; border: 1.5px solid var(--line); color: var(--ink-faint);
	font-family: var(--ps-sans); font-size: 12px; font-weight: 700;
	display: flex; align-items: center; justify-content: center;
	transition: border-color .15s ease, color .15s ease, transform .15s ease;
}
.journey-label { font-family: var(--ps-sans); font-size: 12.5px; font-weight: 600; color: var(--ink-faint); white-space: nowrap; transition: color .15s ease; }
a.journey-step:hover .journey-dot, a.journey-step:focus-visible .journey-dot { border-color: var(--teal-700); color: var(--teal-800); transform: scale(1.08); }
a.journey-step:hover .journey-label, a.journey-step:focus-visible .journey-label { color: var(--teal-900); text-decoration: underline; text-underline-offset: 3px; }
.journey-step.current .journey-dot { background: var(--teal-800); border-color: var(--teal-800); color: #fff; }
.journey-step.current .journey-label { color: var(--teal-900); }
.journey-here {
	margin-inline-start: 8px; flex: none;
	background: var(--teal-800); color: #fff; border-radius: var(--radius-pill); padding: 4px 10px;
	font-family: var(--ps-sans); font-size: 10.5px; font-weight: 700; letter-spacing: .04em;
}
.journey-sep { width: 20px; height: 1.5px; background: var(--line); flex: none; margin: 0 12px; }

.journey-branch { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 13px; padding-top: 12px; border-top: 1px dashed var(--teal-300); }
.branch-chip {
	display: inline-flex; align-items: center; gap: 7px; min-height: 38px; text-decoration: none;
	background: #fff; border: 1px solid var(--teal-300); border-radius: var(--radius-pill); padding: 7px 15px;
	font-family: var(--ps-sans); font-size: 12.5px; font-weight: 600; color: var(--teal-800); white-space: nowrap;
	transition: border-color .15s ease, box-shadow .15s ease;
}
.branch-chip svg { width: 15px; height: 15px; flex: none; }
a.branch-chip:hover, a.branch-chip:focus-visible { border-color: var(--teal-700); box-shadow: var(--shadow-sm); }
.branch-chip.current { background: var(--teal-800); border-color: var(--teal-800); color: #fff; }
.branch-chip--rosa { background: linear-gradient(135deg, #FFF6F8 0%, #FCE4EC 100%); border-color: #F3C6D6; color: #B44873; }
a.branch-chip--rosa:hover, a.branch-chip--rosa:focus-visible { border-color: #E88AA8; }
.branch-chip--rosa.current { background: linear-gradient(135deg, var(--rosa) 0%, #B44873 100%); border-color: #B44873; color: #fff; }

/* ---------- Small notes and alerts ---------- */
.note-soft {
	display: flex; gap: 11px; align-items: flex-start; margin-top: 4px;
	background: var(--mint-50); border: 1px solid var(--line); border-radius: var(--radius-s); padding: 14px 16px;
}
.note-soft svg { width: 17px; height: 17px; color: var(--teal-700); flex: none; margin-top: 2px; }
.detail-main .note-soft p, .note-soft p { font-size: 13.2px; line-height: 1.6; color: var(--ink-soft); }
.note-soft p strong { font-family: var(--ps-sans); color: var(--teal-900); }

.alert-urgent {
	display: flex; gap: 16px; align-items: flex-start;
	background: #FDF4F5; border: 1px solid #EFC6CA; border-inline-start: 5px solid var(--red);
	border-radius: var(--radius-s); padding: 20px 22px; margin-bottom: 36px;
}
.alert-urgent .a-icon {
	width: 42px; height: 42px; border-radius: 50%; background: var(--red); color: #fff; flex: none;
	display: flex; align-items: center; justify-content: center;
}
.alert-urgent .a-icon svg { width: 23px; height: 23px; }
.alert-urgent h2 { font-size: 18px; color: #8C1F2B; margin-bottom: 5px; }
.detail-main .alert-urgent p, .alert-urgent p { font-size: 14.5px; line-height: 1.6; color: #6A2830; max-width: 60ch; }
.alert-urgent.alert-warn { background: #FDF7EC; border-color: #EBD3A6; border-inline-start-color: var(--orange); }
.alert-urgent.alert-warn .a-icon { background: var(--orange); }
.detail-main .alert-urgent.alert-warn p, .alert-urgent.alert-warn p { color: #6B4A18; }

/* ---------- Section head ---------- */
.sec-head { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.sec-head .s-icon {
	width: 34px; height: 34px; border-radius: 9px; background: var(--teal-800); color: #fff;
	display: flex; align-items: center; justify-content: center; flex: none;
}
.sec-head .s-icon svg { width: 19px; height: 19px; }
.sec-head h2 { font-size: 21px; }
.detail-main .sec-intro, .sec-intro { color: var(--ink-soft); font-size: 15px; line-height: 1.65; max-width: 62ch; margin-bottom: 18px; }

/* ---------- "Now" cards ---------- */
.now-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 26px; }
.now-grid.two { grid-template-columns: 1fr 1fr; }
.now-card {
	position: relative; background: var(--mint-100); border: 1px solid var(--teal-300);
	border-radius: var(--radius-m); padding: 28px 20px 22px; box-shadow: var(--shadow-sm);
}
.now-card .people-meta { margin-top: 12px; }
.now-card .badge-wip { margin-top: 10px; }
.now-num {
	position: absolute; top: -15px; inset-inline-start: 20px; width: 30px; height: 30px; border-radius: 50%;
	background: #fff; border: 2px solid var(--teal-800); color: var(--teal-800);
	font-family: var(--ps-sans); font-weight: 700; font-size: 13.5px;
	display: flex; align-items: center; justify-content: center;
}
.detail-main .now-num, .now-card p.now-num { font-size: 13.5px; line-height: 1; color: var(--teal-800); margin: 0; }
.now-ico {
	width: 46px; height: 46px; border-radius: 13px; background: var(--teal-800); color: #fff;
	display: flex; align-items: center; justify-content: center; margin-bottom: 14px;
}
.now-ico svg { width: 24px; height: 24px; }
.now-card strong { font-family: var(--ps-sans); display: block; font-size: 16px; color: var(--teal-900); margin-bottom: 6px; }
.detail-main .now-card p, .now-card p { font-size: 13.8px; color: var(--ink-soft); line-height: 1.6; }
.detail-main .now-card p + p { margin-top: 0; }

.help-strip { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 18px; }
.help-chip {
	display: flex; align-items: flex-start; gap: 10px; flex: 1 1 260px;
	background: #fff; border: 1px solid var(--teal-300); border-radius: var(--radius-s); padding: 13px 15px;
}
.help-chip svg { width: 18px; height: 18px; color: var(--teal-700); flex: none; margin-top: 2px; }
.detail-main .help-chip p, .help-chip p { font-size: 13.2px; line-height: 1.5; color: var(--ink-soft); }
.help-chip p strong { font-family: var(--ps-sans); color: var(--teal-900); display: block; font-size: 13.2px; }

/* ---------- Checklist: what to have ready ---------- */
.prep { background: var(--mint-100); border: 1px solid var(--teal-300); border-radius: var(--radius-m); padding: 26px 28px; margin-top: 8px; }
.detail-main .prep-lede, .prep-lede { font-size: 14.5px; line-height: 1.65; color: var(--teal-900); opacity: .92; max-width: 62ch; }
.prep-list { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 20px; }
.prep-item { display: flex; gap: 13px; align-items: flex-start; background: #fff; border: 1px solid var(--teal-300); border-radius: var(--radius-s); padding: 15px; }
.prep-item .p-ico { width: 36px; height: 36px; border-radius: 10px; background: var(--mint-100); color: var(--teal-700); flex: none; display: flex; align-items: center; justify-content: center; }
.prep-item .p-ico svg { width: 20px; height: 20px; }
.prep-item strong { font-family: var(--ps-sans); display: block; font-size: 14px; color: var(--teal-900); margin-bottom: 3px; }
.prep-item span.sub { display: block; font-size: 12.8px; color: var(--ink-soft); line-height: 1.5; }
.detail-main .prep-item p { font-size: 12.8px; line-height: 1.5; }

/* ---------- Priority note ---------- */
.prio-note { margin-top: 22px; border: 1px solid var(--teal-300); border-radius: var(--radius-m); padding: 22px 24px; background: var(--mint-50); }
.prio-note h3 { font-size: 16.5px; margin-bottom: 8px; }
.detail-main .prio-note p:not(.prio-seg) { font-size: 14.5px; line-height: 1.65; color: var(--ink-soft); max-width: 62ch; }
.prio-strip { display: flex; gap: 6px; margin: 18px 0 14px; }
.detail-main .prio-seg, .prio-seg { flex: 1; border-radius: 9px; padding: 11px 6px; text-align: center; color: #fff; margin: 0; line-height: 1.3; }
.prio-seg b { display: block; font-family: var(--ps-sans); font-size: 11.5px; font-weight: 700; letter-spacing: .02em; margin-bottom: 3px; }
.prio-seg span { font-size: 11px; opacity: .92; }

/* ---------- Accordions (core/details) ---------- */
.acc { border: 1px solid var(--teal-300); border-radius: var(--radius-s); background: var(--mint-50); margin-bottom: 10px; overflow: hidden; }
.acc[open] { background: #fff; }
.acc > summary {
	list-style: none; cursor: pointer; display: flex; align-items: center; gap: 12px;
	padding: 16px 18px; font-family: var(--ps-sans); font-weight: 600; font-size: 15px; color: var(--teal-900);
}
.acc > summary::-webkit-details-marker { display: none; }
.acc > summary:focus-visible { outline: 2px solid var(--teal-700); outline-offset: -2px; }
/* block port: the summary's icon and chevron are drawn here (a summary holds text only) */
.acc > summary::before, .acc > summary::after {
	content: ""; flex: none; background: currentColor;
	-webkit-mask: var(--ps-ico) center / contain no-repeat; mask: var(--ps-ico) center / contain no-repeat;
}
.acc > summary::before { width: 19px; height: 19px; color: var(--teal-700); }
.acc > summary::after {
	--ps-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
	width: 18px; height: 18px; color: var(--teal-600); margin-inline-start: auto; transition: transform .2s ease;
}
.acc[open] > summary::after { transform: rotate(180deg); }
.acc-body { padding: 0 18px 18px; padding-inline-start: 49px; }
.detail-main .acc-body p { font-size: 14.5px; color: var(--ink-soft); line-height: 1.7; }
.acc-body .list-plain { margin-top: 4px; }

/* ---------- Sidebar ---------- */
.sidebar { position: sticky; top: calc(var(--ps-topbar-h) + 24px); }
.help-card { background: var(--mint-100); border: 1px solid var(--teal-300); border-radius: var(--radius-m); padding: 22px; margin-bottom: 18px; }
.help-card h3 { font-size: 16px; margin-bottom: 14px; }
.help-row { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--teal-300); }
.help-row:first-of-type { border-top: none; padding-top: 0; }
.help-row svg { width: 19px; height: 19px; color: var(--teal-700); flex: none; margin-top: 2px; }
.help-row strong { font-family: var(--ps-sans); display: block; font-size: 13.4px; color: var(--teal-900); margin-bottom: 3px; }
.help-row p { font-size: 12.8px; color: var(--ink-soft); line-height: 1.55; }
.help-row a { color: var(--teal-800); font-weight: 600; }
.safety-card { background: var(--plum-700); color: #fff; border-radius: var(--radius-m); padding: 24px; }
.safety-card .safety-head { display: flex; gap: 10px; align-items: center; margin-bottom: 16px; }
.safety-card .safety-head svg { width: 20px; height: 20px; flex: none; }
.safety-card h3 { color: #fff; font-size: 16.5px; margin: 0; }
.safety-item { padding: 14px 0; border-top: 1px solid rgba(255, 255, 255, .16); }
.safety-item strong { font-family: var(--ps-sans); display: block; font-size: 13.3px; margin-bottom: 4px; color: #fff; }
.safety-item p { font-size: 12.8px; line-height: 1.55; color: rgba(255, 255, 255, .82); }
.safety-item a { color: #fff; text-decoration: underline; }

/* ---------- Interpreter notice (client requirement, not in the brief) ---------- */
.ps-interp {
	width: min(440px, calc(100vw - 32px)); border: none; padding: 28px 26px 22px;
	border-radius: var(--radius-m); background: #fff; color: var(--ink); box-shadow: var(--shadow);
	text-align: center;
}
.ps-interp::backdrop { background: rgba(6, 67, 47, .55); }
.ps-interp__icon {
	width: 52px; height: 52px; border-radius: 50%; background: var(--teal-800); color: #fff;
	display: inline-flex; align-items: center; justify-content: center; margin-bottom: 14px;
}
.ps-interp__icon svg { width: 26px; height: 26px; }
.ps-interp__text { font-family: var(--ps-sans); font-weight: 600; font-size: 18px; line-height: 1.4; color: var(--teal-900); }
.ps-interp__actions { margin: 20px 0 0; }
.ps-interp__close {
	border: none; border-radius: var(--radius-s); background: var(--teal-800); color: #fff;
	padding: 12px 26px; font-family: var(--ps-sans); font-weight: 600; font-size: 14px; min-height: 44px;
}
.ps-interp__close:hover { background: var(--teal-900); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
	.hero-v3 { grid-template-columns: 1fr; gap: 24px; }
	.menu-grid { grid-template-columns: 1fr; }
	.detail-layout { grid-template-columns: 1fr; gap: 0; }
	.sidebar { position: static; margin-top: 10px; }
	.code-grid { grid-template-columns: repeat(2, 1fr); }
	.card-grid { grid-template-columns: 1fr; }
	.where-list { grid-template-columns: 1fr; }
	.band-inner { flex-direction: column; align-items: flex-start; text-align: start; }
	.cta-box { flex-direction: column; align-items: flex-start; }
	.now-grid { grid-template-columns: 1fr; gap: 24px; }
	.now-grid.two { grid-template-columns: 1fr; }
	.prep-list { grid-template-columns: 1fr; }
	.prep { padding: 22px 18px; }
	.prio-strip { flex-wrap: wrap; }
	.detail-main .prio-seg, .prio-seg { flex: 1 1 30%; }
	.acc-body { padding-inline-start: 18px; }
	.alert-urgent { padding: 18px; }
	.journey { padding: 12px 14px; }
	.journey-sep { margin: 0 8px; width: 14px; }
}
@media (max-width: 600px) {
	.journey { padding: 12px; }
	.journey-track { justify-content: space-between; overflow-x: visible; }
	.journey-item:not(:first-child) { flex: 1 1 auto; }
	.journey-step { gap: 0; padding: 4px; }
	.journey-step:not(.current) .journey-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
	.journey-step.current { gap: 8px; }
	.journey-step.current .journey-label { font-size: 12px; }
	.journey-here { margin-inline-start: 6px; padding: 3px 8px; font-size: 9.5px; }
	.journey-sep { margin: 0 4px; width: auto; flex: 1 1 auto; min-width: 8px; }
	.journey-branch { gap: 7px; margin-top: 11px; padding-top: 11px; }
	.branch-chip { flex: 1 1 100%; justify-content: flex-start; white-space: normal; text-align: start; min-height: 42px; }
	.detail-header h1 { font-size: 26px; }
}
@media (max-width: 480px) {
	.topbar-inner { padding-block: 12px; gap: 10px; }
	.topbar-tag { display: none; } /* the hero CTA and "Torna alla guida" cover it */
	.brand-text strong { font-size: 15px; }
}

/* ---------- Accordion icons (core/details class "ps-ico-<name>") ----------
 * Generated from inc/icons.php for the icons the content uses. To offer another,
 * add a line here with that icon's paths. */
.acc.ps-ico-users-2 > summary::before { --ps-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='8' r='3'/%3E%3Ccircle cx='16.5' cy='9' r='2.3'/%3E%3Cpath d='M4 19c.8-3 8.2-3 10 0M16 13.5c2.5.3 4 1.6 4 3.5'/%3E%3C/svg%3E"); }
.acc.ps-ico-mask > summary::before { --ps-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 10.5c1.5-2 4.5-3 8.5-3s7 1 8.5 3c-.8 3.5-2 5-2 5H5.5s-1.2-1.5-2-5z'/%3E%3Cpath d='M12 7.5v-2M8 19h8'/%3E%3C/svg%3E"); }
.acc.ps-ico-cctv > summary::before { --ps-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 8.5l13-4v15l-13-4z'/%3E%3Ccircle cx='16' cy='12' r='4.5'/%3E%3Ccircle cx='16' cy='12' r='1.5'/%3E%3C/svg%3E"); }
.acc.ps-ico-id-badge > summary::before { --ps-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4.5' y='3' width='15' height='18' rx='2'/%3E%3Ccircle cx='12' cy='10' r='3'/%3E%3Cpath d='M8 17.5c1-2 7-2 8 0'/%3E%3C/svg%3E"); }
.acc.ps-ico-search > summary::before { --ps-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='M16 16l4.5 4.5'/%3E%3C/svg%3E"); }
.acc.ps-ico-file-text > summary::before { --ps-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 3.5H7.5a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2h9a2 2 0 0 0 2-2V8z'/%3E%3Cpath d='M13.8 3.5V8h4.7'/%3E%3Cpath d='M9 13h6M9 16h4'/%3E%3C/svg%3E"); }
.acc.ps-ico-mail > summary::before { --ps-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5.5' width='18' height='13' rx='2'/%3E%3Cpath d='M3.5 7l8.5 6 8.5-6'/%3E%3C/svg%3E"); }

/* ---------- Port fixes ----------
 * 1. The brief styles every <strong> in a card as a block title. Inside running
 *    text ("il <strong>verbale</strong>", "Chiama il <strong>1522</strong>") that
 *    broke the sentence onto three lines — in the brief too. Titles are now the
 *    paragraphs marked .is-title; any other strong stays inline.
 * 2. Triage colour cards inside a detail page must not take .detail-main's grey ink. */
.now-card p:not(.is-title) strong, .info-card p:not(.is-title) strong,
.cta-body p:not(.is-title) strong, .contact-card p:not(.is-title) strong,
.people-body p:not(.is-title) strong, .safety-item p:not(.is-title) strong {
	display: inline; font-family: inherit; font-size: inherit; margin: 0; color: var(--teal-900);
}
.cta-alert .cta-body p:not(.is-title) strong { color: var(--red); }
.detail-main .code-card p { color: inherit; line-height: 1.25; }
.detail-main .code-card p:not(.code-name, .code-time, .code-label) { font-size: 10.5px; line-height: 1.4; color: rgba(255, 255, 255, .88); }
/* 3. RTL: phone numbers are written with spaces ("02 8224 8392"); in an Arabic
 *    paragraph the bidi algorithm reverses the digit groups. Isolate them as LTR. */
a[href^="tel:"], a[href^="mailto:"] { direction: ltr; unicode-bidi: isolate; }
