/*
  Filippo Palmieri — tema "Chrome 1.0" (2008), reinterpretato in modo pulito.
  Layout: la pagina vive dentro una finestra del browser (schede, barra degli strumenti,
  barra dei preferiti); il contenuto è su fondo bianco, con una griglia di lavori
  ispirata alla pagina "Più visitati".
*/

:root {
  /* cornice del browser: azzurro-grigio metallico */
  --frame-top: #cbd9ec;
  --frame-bottom: #b5cae4;
  --frame-line: #8ea6c5;
  --bar-top: #f4f7fc;
  --bar-bottom: #dfe8f5;
  --bar-line: #a9bcd6;

  /* area contenuto */
  --page: #ffffff;
  --panel: #f9f9f9;
  --desk: #e7ecf3;
  --line: #d3dae4;
  --line-strong: #b9c4d3;

  /* testo e link */
  --ink: #111111;
  --ink-soft: #4a5566;
  --link: #1a47d6;
  --link-visited: #5b2aa0;

  /* bottoni gel */
  --gel-border: #7c94b6;
  --gel-text: #1d2b44;

  /* stati dei lavori */
  --pub: #2f6fd6;
  --talk: #2e8a57;
  --ms: #b8781a;
  --cv: #6b7a90;
  --thesis: #6a4fa8;

  --focus: #1a47d6;
  --target: #fff5c2;

  --ui: "Segoe UI", Tahoma, Verdana, Arial, sans-serif;

  color-scheme: light;
}

/* ---------- base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--desk);
  color: var(--ink);
  font-family: var(--ui);
  font-size: 15px;
  line-height: 1.6;
}

[hidden] { display: none !important; }
.no-js .needs-js { display: none !important; }

/* Lingue: ogni testo esiste in due versioni; si vede solo quella attiva. Senza JavaScript resta l'italiano. */
html:not([lang="en-GB"]) [data-l="en"],
html[lang="en-GB"] [data-l="it"] { display: none !important; }

p { margin: 0 0 0.9rem; }

a { color: var(--link); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.15em; }
a:visited { color: var(--link-visited); }
a:hover { text-decoration-thickness: 2px; }

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  box-shadow: 0 0 0 5px rgba(26, 71, 214, 0.18);
}

.skip {
  position: absolute; left: 0.5rem; top: -10rem; z-index: 50;
  padding: 0.4rem 0.7rem; background: #ffffff; color: var(--ink); border: 1px solid var(--frame-line);
}
.skip:focus { top: 0.5rem; }

.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- scrivania e finestra ---------- */

.desk { padding: 24px 24px 40px; }

.window {
  max-width: 1080px;
  margin: 0 auto;
  border: 1px solid var(--frame-line);
  border-radius: 7px 7px 3px 3px;
  background: var(--page);
  box-shadow: 0 6px 22px rgba(40, 62, 98, 0.18), 0 1px 3px rgba(40, 62, 98, 0.12);
}

/* La cornice resta in alto mentre la pagina scorre, come in un browser vero */
.chrome {
  position: sticky;
  top: 0;
  z-index: 20;
  border-radius: 6px 6px 0 0;
  background: linear-gradient(to bottom, var(--frame-top), var(--frame-bottom));
}

/* ---------- barra delle schede ---------- */

.tabstrip {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 38px;
  padding: 0 12px;
}

.tab {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 260px;
  min-width: 0;
  height: 29px;
  padding: 0 26px 0 22px;
  font-size: 12.5px;
  color: var(--ink);
}

/* il trapezio della scheda: rettangolo smussato messo in prospettiva */
.tab::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border: 1px solid var(--frame-line);
  border-bottom: 0;
  border-radius: 6px 6px 0 0;
  background: linear-gradient(to bottom, #ffffff 0%, var(--bar-top) 100%);
  box-shadow: inset 0 1px 0 #ffffff;
  transform: perspective(14px) rotateX(2.4deg);
  transform-origin: bottom;
}

.tab-icon { flex: none; display: block; }
.tab-title { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }

/* più schede: quella attiva è chiara e si unisce alla barra; le altre restano velate */
a.tab { text-decoration: none; cursor: pointer; }
a.tab:visited { color: var(--ink); }
.tab-home { flex: 0 1 250px; }
.tab-more { flex: 0 1 150px; padding: 0 18px 0 18px; color: #22334d; }
a.tab-more:visited { color: #22334d; }
.tab:not(.tab-active)::before {
  background: linear-gradient(to bottom, rgba(255,255,255,0.62) 0%, rgba(255,255,255,0.30) 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.7);
}
.tab:not(.tab-active):hover::before { background: linear-gradient(to bottom, rgba(255,255,255,0.9) 0%, rgba(255,255,255,0.55) 100%); }
.tab-active { z-index: 2; }
.tab:focus-visible { outline-offset: -3px; box-shadow: none; }

.newtab {
  display: grid;
  place-items: center;
  width: 26px;
  height: 20px;
  margin: 0 0 4px 10px;
  border: 1px solid var(--frame-line);
  border-radius: 4px;
  background: linear-gradient(to bottom, rgba(255,255,255,0.75) 0%, rgba(255,255,255,0.45) 50%, rgba(255,255,255,0.2) 50%, rgba(255,255,255,0.4) 100%);
  color: #3a5274;
  font-size: 16px;
  font-weight: bold;
  line-height: 1;
  text-decoration: none;
  transform: skewX(-14deg);
}
.newtab span { transform: skewX(14deg); }
.newtab:visited { color: #3a5274; }
.newtab:hover { background: linear-gradient(to bottom, #ffffff 0%, #f1f6fd 50%, #dbe7f6 50%, #e7eff9 100%); }

/* ---------- barra degli strumenti ---------- */

.toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px 7px;
  background: linear-gradient(to bottom, var(--bar-top), #e9f0f9);
  border-top: 1px solid #ffffff;
}

.nav-buttons { display: flex; gap: 4px; flex: none; }

/* ---------- bottoni gel ---------- */

.gel {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 30px;
  padding: 0 14px;
  border: 1px solid var(--gel-border);
  border-radius: 4px;
  background: linear-gradient(to bottom, #ffffff 0%, #f2f6fb 50%, #dee7f3 50%, #e9eff8 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.95), inset 0 -1px 2px rgba(110,140,185,0.22), 0 1px 0 rgba(255,255,255,0.7);
  color: var(--gel-text);
  font: inherit;
  font-size: 13.5px;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
}
.gel:visited { color: var(--gel-text); }
.gel:hover {
  border-color: #5c80b6;
  background: linear-gradient(to bottom, #ffffff 0%, #eaf3ff 50%, #cfe1fa 50%, #deebfb 100%);
  text-decoration: none;
}
.gel:active {
  background: linear-gradient(to bottom, #d5e2f3 0%, #dfe9f6 50%, #e9f0f9 50%, #f3f7fc 100%);
  box-shadow: inset 0 1px 3px rgba(60, 90, 140, 0.35);
}

.gel-round { width: 30px; padding: 0; color: #2f4e7c; }
.gel-round svg { display: block; }

.gel-small { min-height: 24px; padding: 0 9px; font-size: 12px; }

.gel-primary {
  border-color: #4c71ab;
  background: linear-gradient(to bottom, #f7fbff 0%, #e2eeff 50%, #c2d8f8 50%, #d4e4fb 100%);
  color: #0f2a57;
  font-weight: bold;
}
.gel-primary:visited { color: #0f2a57; }
.gel-primary:hover { background: linear-gradient(to bottom, #ffffff 0%, #d9e9ff 50%, #aecbf5 50%, #c3dafa 100%); }

/* ---------- omnibox ---------- */

.omnibox {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  height: 30px;
  padding: 0 10px 0 8px;
  border: 1px solid #8fa5c4;
  border-radius: 3px;
  background: #ffffff;
  box-shadow: inset 0 1px 2px rgba(60, 90, 140, 0.18);
  font-size: 14px;
}
.omni-star { flex: none; }
.url {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: var(--ink);
}
.url-scheme { color: #1f7a3a; }
.url-sep, .url-path { color: #6b7686; }

.lang { display: flex; gap: 4px; flex: none; }
.lang a[aria-current] {
  border-color: #4c71ab;
  background: linear-gradient(to bottom, #e3ecf8 0%, #d6e3f4 50%, #c8d9f0 50%, #d3e1f3 100%);
  box-shadow: inset 0 1px 3px rgba(60, 90, 140, 0.35);
  font-weight: bold;
  cursor: default;
}

/* ---------- barra dei preferiti ---------- */

.bookmarks {
  background: linear-gradient(to bottom, #e9f0f9, var(--bar-bottom));
  border-bottom: 1px solid var(--bar-line);
}
.bookmarks ul {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 4px;
  margin: 0;
  padding: 3px 8px 4px;
  list-style: none;
}
.bookmarks a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 8px;
  border: 1px solid transparent;
  border-radius: 3px;
  color: var(--ink);
  font-size: 12.5px;
  line-height: 18px;
  text-decoration: none;
}
.bookmarks a:visited { color: var(--ink); }
.bookmarks a:hover {
  border-color: #9db3d2;
  background: linear-gradient(to bottom, #ffffff 0%, #eef4fc 50%, #dde8f6 50%, #e8eff9 100%);
}
.bookmarks .bm-right { margin-left: auto; }
/* computer: preferiti verso l'esterno; telefono: preferiti verso le sezioni */
.bookmarks .bm-sections { display: none; }

.ico { flex: none; display: block; width: 16px; height: 16px; }

/* ---------- pagina ---------- */

.page {
  padding: 34px 40px 28px;
  border-radius: 0 0 3px 3px;
  background: var(--page);
}
.page:focus { outline: none; }

section, .view { scroll-margin-top: 130px; }
section { margin-bottom: 40px; }

h1 {
  margin: 0;
  font-size: 34px;
  font-weight: bold;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.subtitle { margin: 4px 0 22px; color: var(--ink-soft); font-size: 16px; }

/* intestazioni di sezione nello stile della pagina iniziale di Chrome */
.ntp-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: linear-gradient(to bottom, #fbfcfe, #edf1f7);
  font-size: 16px;
  font-weight: bold;
  line-height: 1.4;
  color: #1d2b44;
}

/* ---------- schede: una sezione alla volta (solo computer, con JavaScript) ---------- */

html.tabbed .view:not(.is-current) { display: none; }
/* una scheda si apre sempre dall'alto della finestra */
html.tabbed .view { scroll-margin-top: 100vh; }
html.tabbed .page { display: flex; flex-direction: column; min-height: calc(100vh - 150px); }
html.tabbed .site-footer { margin-top: auto; }
.view > h2:focus, .view h1:focus { outline: none; }

/* ---------- pagina d'errore (404.html) ---------- */

.err { min-height: 60vh; text-align: center; padding-top: 56px; padding-bottom: 56px; }
.tab-wide { flex-basis: 340px; max-width: 340px; }
.err-icon { display: block; margin: 0 auto 18px; }
.err h1 { margin-bottom: 10px; font-size: 28px; }
.err h2 { margin: 26px 0 8px; font-size: 18px; color: #1d2b44; }
.err p { max-width: 56ch; margin-left: auto; margin-right: auto; }
.err-en { padding-top: 4px; border-top: 1px solid var(--line); max-width: 60ch; margin: 22px auto 0; }
.err .cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 26px; }

/* ---------- cosa posso scrivere ---------- */

.topics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin: 0 0 22px;
  padding: 0;
  list-style: none;
}
.topic {
  padding: 12px 16px 6px;
  border: 1px solid #c7cfda;
  border-radius: 3px;
  background: linear-gradient(to bottom, #ffffff 0%, #ffffff 60%, #f6f8fc 100%);
  box-shadow: 0 2px 3px rgba(30, 50, 80, 0.08);
}
.topic-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 6px;
  font-size: 15px;
  line-height: 1.35;
  color: #1d2b44;
}
.topic p { margin-bottom: 0.6rem; }
.topic-base { color: var(--ink-soft); font-size: 13px; }

/* barra della griglia dei lavori: titolo a sinistra, data dell'elenco a destra */
.ntp-bar { justify-content: space-between; flex-wrap: wrap; gap: 2px 14px; }
.ntp-bar h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: inherit;
  line-height: inherit;
}
.ntp-date { margin: 0; color: var(--ink-soft); font-size: 12.5px; font-weight: normal; }

.note { margin: -4px 0 18px; color: var(--ink-soft); font-size: 13.5px; }
.text { max-width: 74ch; }

/* ---------- apertura ---------- */

.intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  column-gap: 40px;
  align-items: start;
}
.lead-text { min-width: 0; }
.lead { max-width: 66ch; font-size: 16px; line-height: 1.65; }

sup.ref { font-size: 0.72em; line-height: 0; white-space: nowrap; }
sup.ref a { text-decoration: none; }
sup.ref a:hover { text-decoration: underline; }

.cta { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0 0; }

/* disponibilità per commissioni, in apertura */
.avail {
  max-width: 66ch;
  margin: 18px 0 0;
  padding: 12px 16px 14px;
  border: 1px solid #c7d3e6;
  border-radius: 3px;
  background: linear-gradient(to bottom, #f7faff, #edf3fc);
}
.avail-text { margin: 0; font-size: 15px; line-height: 1.55; }
.avail-label { margin: 10px 0 6px; color: var(--ink-soft); font-size: 12.5px; font-weight: bold; text-transform: uppercase; letter-spacing: 0.05em; }
.avail-topics { display: flex; flex-wrap: wrap; gap: 6px 8px; margin: 0; padding: 0; list-style: none; }
.avail-topics a {
  display: inline-block;
  padding: 2px 10px;
  border: 1px solid #9db3d2;
  border-radius: 3px;
  background: linear-gradient(to bottom, #ffffff 0%, #ffffff 50%, #eef3fa 50%, #f4f7fc 100%);
  color: var(--gel-text);
  font-size: 13px;
  line-height: 20px;
  text-decoration: none;
}
.avail-topics a:visited { color: var(--gel-text); }
.avail-topics a:hover { border-color: #5c80b6; text-decoration: underline; }
.cta .gel { min-height: 34px; padding: 0 18px; font-size: 14px; }

/* scheda (infobox) */
.infobox {
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background: var(--panel);
  font-size: 13px;
  line-height: 1.4;
  box-shadow: 0 1px 3px rgba(40, 62, 98, 0.08);
}
.ib-title {
  margin: 0;
  padding: 6px 10px;
  border-bottom: 1px solid var(--line-strong);
  border-radius: 3px 3px 0 0;
  background: linear-gradient(to bottom, #f7fbff 0%, #e2eeff 50%, #c9dcf7 50%, #d8e6fa 100%);
  font-weight: bold;
  font-size: 14px;
  text-align: center;
  color: #0f2a57;
}
.ib-photo { padding: 10px; border-bottom: 1px solid var(--line); text-align: center; background: #ffffff; }
.ib-photo img {
  display: block;
  width: 118px;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
  border: 1px solid var(--line-strong);
}
.infobox table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.infobox th, .infobox td {
  padding: 5px 8px;
  border-top: 1px solid var(--line);
  vertical-align: top;
  text-align: left;
  overflow-wrap: anywhere;
}
.infobox tr:first-child th, .infobox tr:first-child td { border-top: 0; }
.infobox th { width: 37%; background: #eef2f8; font-weight: bold; color: #1d2b44; border-right: 1px solid var(--line); }

/* ---------- griglia "più visitati" ---------- */

.tiles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tile {
  display: flex;
  flex-direction: column;
  padding: 8px 8px 12px;
  border: 1px solid #c7cfda;
  border-radius: 3px;
  background: #ffffff;
  box-shadow: 0 2px 3px rgba(30, 50, 80, 0.10);
  scroll-margin-top: 140px;
}
.tile:not(.tile-static):hover,
.tile:focus-within {
  border-color: #92abcf;
  box-shadow: 0 5px 14px rgba(30, 50, 80, 0.20);
}
@media (prefers-reduced-motion: no-preference) {
  .tile { transition: box-shadow 0.15s ease, border-color 0.15s ease; }
}
.tile:target { background: var(--target); }

.tile-link { display: block; color: var(--ink); text-decoration: none; }
a.tile-link:visited { color: var(--ink); }
a.tile-link:hover .tile-title > span:last-child { text-decoration: underline; color: var(--link); }

/* anteprima: una pagina in miniatura, disegnata con il CSS */
.thumb {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 7px;
  aspect-ratio: 16 / 9;
  max-width: 100%;
  padding: 0 0 10px;
  overflow: hidden;
  border: 1px solid #dde3ec;
  background: linear-gradient(to bottom, #ffffff, #f4f7fb);
}
.th-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding: 0 9px;
  color: #ffffff;
  font-size: 11.5px;
  font-weight: bold;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
}
.th-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,0.85); }
.th-h, .th-l { display: block; margin: 0 10px; border-radius: 2px; }
.th-h { height: 9px; width: 72%; background: #b7c2d2; margin-top: 4px; }
.th-l { height: 5px; width: 88%; background: #e0e6ee; }
.th-s { width: 55%; }
.th-t {
  display: block;
  margin: 3px 10px 1px;
  color: #26354d;
  font-size: 12.5px;
  font-weight: bold;
  line-height: 1.25;
}
/* l'attacco vero dell'articolo, come nella miniatura di una pagina */
.th-x {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
  margin: 0 10px;
  color: #2f3a4b;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 13px;
  line-height: 1.4;
}

.thumb-pub .th-bar { background: linear-gradient(to bottom, #5d93e6, var(--pub)); }
.thumb-talk .th-bar { background: linear-gradient(to bottom, #58b07f, var(--talk)); }
.thumb-ms .th-bar { background: linear-gradient(to bottom, #d79b3e, var(--ms)); }
.thumb-thesis .th-bar { background: linear-gradient(to bottom, #8a72c4, var(--thesis)); }

.thumb-cv { align-items: center; justify-content: center; padding: 10px; background: linear-gradient(to bottom, #eef2f8, #e2e8f1); }
.th-page {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 42%;
  height: 100%;
  padding: 10px 0;
  border: 1px solid #c3ccd9;
  background: #ffffff;
  box-shadow: 0 1px 3px rgba(30, 50, 80, 0.15);
}
.th-page .th-h { margin: 0 8px 2px; width: 60%; height: 7px; }
.th-page .th-l { margin: 0 8px; height: 4px; }

.tile-title {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 10px;
  font-size: 14px;
  font-weight: bold;
  line-height: 1.35;
}
.fav {
  flex: none;
  display: grid;
  place-items: center;
  width: 16px;
  height: 16px;
  margin-top: 1px;
  border-radius: 2px;
  color: #ffffff;
  font-size: 7.5px;
  font-weight: bold;
  letter-spacing: -0.02em;
}
.fav-pub { background: var(--pub); }
.fav-talk { background: var(--talk); }
.fav-ms { background: var(--ms); }
.fav-cv { background: var(--cv); }
.fav-thesis { background: var(--thesis); }

.tile-meta { margin: 8px 0 6px 24px; color: var(--ink-soft); font-size: 12.5px; line-height: 1.5; }
.tile-desc { margin: 0 0 0 24px; font-size: 13.5px; line-height: 1.5; }

.chip {
  display: inline-block;
  margin-right: 4px;
  padding: 0 6px;
  border: 1px solid;
  border-radius: 3px;
  font-size: 11.5px;
  font-weight: bold;
  line-height: 17px;
  white-space: nowrap;
  background: linear-gradient(to bottom, #ffffff 0%, #ffffff 50%, #f1f4f8 50%, #f6f8fb 100%);
}
.chip-pub { color: #1f53a8; border-color: #9cb8e3; }
.chip-talk { color: #22673f; border-color: #9ccbb0; }
.chip-ms { color: #8a5810; border-color: #ddbb85; }
.chip-cv { color: #44516a; border-color: #b9c4d3; }
.chip-thesis { color: #563d8f; border-color: #c2b3e0; }

/* link ai testi completi in PDF, sotto la descrizione */
.tile-files { margin: 8px 0 0 24px; padding-top: 7px; border-top: 1px dotted var(--line-strong); font-size: 12.5px; line-height: 1.5; color: var(--ink-soft); }

/* sottotitoli dentro la sezione Lavori */
.works-sub {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 22px 0 12px;
  color: #1d2b44;
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.works-sub::after { content: ""; flex: 1; border-top: 1px solid var(--line); }
.note + .works-sub { margin-top: 6px; }

/* ---------- ricerca ---------- */

.themes { max-width: 74ch; margin: 0; padding-left: 1.6rem; }
.themes li { margin-bottom: 4px; padding-left: 4px; }
.themes li::marker { color: #6f86a8; font-weight: bold; }

/* ---------- chi sono ---------- */

.about-cols {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 36px;
  align-items: start;
}
.cv { margin-top: 16px; }

.list-title {
  margin: 0 0 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  font-weight: bold;
  color: #1d2b44;
}
.timeline { margin: 0; padding: 0; list-style: none; }
.timeline li {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px dotted var(--line-strong);
}
.timeline li:last-child { border-bottom: 0; }
.timeline time { color: var(--ink-soft); font-size: 12.5px; font-variant-numeric: tabular-nums; padding-top: 2px; }
.tl-title { margin: 0; font-weight: bold; font-size: 14px; line-height: 1.4; }
.tl-meta { margin: 3px 0 0; color: var(--ink-soft); font-size: 12.5px; }
.tl-desc { margin: 5px 0 0; font-size: 13.5px; }

/* ---------- contatti ---------- */

.contact-cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 360px);
  gap: 36px;
  align-items: start;
}
.services { margin: 0 0 14px; padding-left: 1.3rem; list-style: square; }
.services li { margin-bottom: 3px; }
.services li::marker { color: #6f86a8; }

.panel {
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background: var(--panel);
  box-shadow: 0 1px 3px rgba(40, 62, 98, 0.08);
}
.panel-title {
  margin: 0;
  padding: 6px 12px;
  border-bottom: 1px solid var(--line-strong);
  background: linear-gradient(to bottom, #fbfcfe, #e9eef6);
  font-weight: bold;
  font-size: 13.5px;
  color: #1d2b44;
}
.contact-list {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 8px 14px;
  margin: 0;
  padding: 12px 14px;
  font-size: 14px;
}
.contact-list dt { color: var(--ink-soft); font-size: 13px; line-height: 1.6; }
.contact-list dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }

/* ---------- piè di pagina ---------- */

.site-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 12.5px;
}
.site-footer p { margin: 0; }

/* ---------- schermi medi ---------- */

@media (max-width: 900px) {
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about-cols, .contact-cols { grid-template-columns: minmax(0, 1fr); gap: 24px; }
}

@media (max-width: 760px) {
  /* niente schede multiple: la pagina si legge scorrendo, i preferiti portano alle sezioni */
  .tab-more { display: none; }
  .bookmarks .bm-links { display: none; }
  .bookmarks .bm-sections { display: flex; }
  .topics { grid-template-columns: minmax(0, 1fr); }
  .intro { grid-template-columns: minmax(0, 1fr); }
  .infobox { max-width: 380px; margin-top: 26px; }
}

/* ---------- telefono ---------- */

@media (max-width: 600px) {
  .desk { padding: 0; }
  .window { border: 0; border-radius: 0; box-shadow: none; }
  .chrome { position: static; border-radius: 0; }
  section, .view, .tile { scroll-margin-top: 12px; }
  /* cornice più sottile: il nome compare prima, i preferiti stanno su una riga */
  .tabstrip { height: 30px; padding: 0 8px; }
  .tab { height: 25px; padding: 0 20px 0 16px; max-width: 76vw; font-size: 12px; }
  .newtab { height: 18px; margin-bottom: 3px; }
  .toolbar { gap: 6px; padding: 4px 8px 5px; }
  .bookmarks .ico { display: none; }
  .bookmarks ul { justify-content: space-between; gap: 0; padding: 2px 4px 3px; }
  .bookmarks a { padding: 3px 7px; }
  .nav-buttons { gap: 3px; }
  .gel-round { width: 28px; min-height: 28px; }
  .omnibox { height: 28px; font-size: 13px; padding: 0 8px 0 6px; gap: 6px; }
  .url-scheme, .url-sep { display: none; }
  /* sul telefono il CV resta nella griglia dei lavori e in Chi sono */
  .bookmarks .bm-sections .bm-right { display: none; }
  .page { padding: 24px 16px 20px; }
  h1 { font-size: 28px; }
  .tiles { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .infobox { max-width: none; }
  .timeline li { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .contact-list { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .contact-list dd { margin-bottom: 8px; }
}

@media (max-width: 360px) {
  .nav-buttons [data-action="forward"] { display: none; }
  .bookmarks a { padding: 3px 4px; font-size: 12px; }
  .ntp-bar { padding-left: 9px; padding-right: 9px; }
}

/* ---------- stampa ---------- */

@media print {
  body { background: #ffffff; }
  .desk { padding: 0; }
  .window { border: 0; box-shadow: none; }
  .chrome, .cta, .skip, .site-footer .gel { display: none !important; }
  html.tabbed .view { display: block !important; }
  html.tabbed .page { display: block; min-height: 0; }
  .page { padding: 0; }
  .tile { break-inside: avoid; box-shadow: none; }
}
