/* Portfolio identity: Futura Light / Dark.
   Optional licensed webfonts: see README_THEME.md. No font binaries bundled. */
@font-face {
  font-family: "Portfolio Futura";
  src: local("Futura Book"), local("Futura-Book"), local("Futura PT Book"), local("FuturaPT-Book");
  font-weight: 300 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Portfolio Futura";
  src: local("Futura Heavy"), local("Futura-Heavy"), local("Futura PT Heavy"), local("FuturaPT-Heavy");
  font-weight: 600 900;
  font-style: normal;
  font-display: swap;
}
/* Headings request the Heavy face through font-weight: 700. */
:root {
  --font-body: "Portfolio Futura", Futura, "Century Gothic", "Trebuchet MS", system-ui, sans-serif;
  --font-display: var(--font-body);
  --midnight: #080C1A;
  --yellow: #FFE100;
  --off-white: #F9F5EE;
  --lavender: #AEB4D4;
  --violet: #67509B;
  color-scheme: light;
  --paper: #FFFFFF;
  --paper-alt: #F7F6FA;
  --panel: #F7F6FA;
  --header: #FFFFFF;
  --card: #FFFFFF;
  --ink: #080C1A;
  --heading: #080C1A;
  --accent: #67509B;
  --accent-line: #FFE100;
  --mid: #30364A;
  --muted: #505773;
  --rule: #D6D4E0;
  --grid: #D6D4E0;
  --grid-line: rgba(103,80,155,.065);
  --button-bg: #080C1A;
  --button-fg: #FFFFFF;
  --button-hover: #67509B;
  --brand: #67509B;
  --framework-logo-filter: brightness(0) saturate(100%);
  --focus: #67509B;
  --logo-surface: #FFFFFF;
  --header-height: 68px;
}
/* The same tokens are applied with or without JS; system preference is the default. */
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #080C1A;
  --paper-alt: #11162A;
  --panel: #11162A;
  --header: #080C1A;
  --card: #11162A;
  --ink: #F9F5EE;
  --heading: #F9F5EE;
  --accent: #FFE100;
  --accent-line: #FFE100;
  --mid: #D5D8E6;
  --muted: #AEB4D4;
  --rule: #373C57;
  --grid: #373C57;
  --grid-line: rgba(174,180,212,.07);
  --button-bg: #FFE100;
  --button-fg: #080C1A;
  --button-hover: #F9F5EE;
  --brand: #FFE100;
  --framework-logo-filter: brightness(0) invert(1);
  --focus: #FFE100;
  --logo-surface: #F9F5EE;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
  color-scheme: dark;
  --paper: #080C1A;
  --paper-alt: #11162A;
  --panel: #11162A;
  --header: #080C1A;
  --card: #11162A;
  --ink: #F9F5EE;
  --heading: #F9F5EE;
  --accent: #FFE100;
  --accent-line: #FFE100;
  --mid: #D5D8E6;
  --muted: #AEB4D4;
  --rule: #373C57;
  --grid: #373C57;
  --grid-line: rgba(174,180,212,.07);
  --button-bg: #FFE100;
  --button-fg: #080C1A;
  --button-hover: #F9F5EE;
  --brand: #FFE100;
  --framework-logo-filter: brightness(0) invert(1);
  --focus: #FFE100;
  --logo-surface: #F9F5EE;
  }
}


  *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
  html { scroll-behavior: smooth; }

  body {
    background: var(--paper);
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.6;
    overflow-x: hidden;
  }


  .hero-title {
    font-family: var(--font-body);
    font-size: clamp(2.8rem, 5vw, 4.5rem);
    font-weight: 300;
    line-height: 1.05;
    color: var(--ink);
    margin-bottom: 2.5rem;
    letter-spacing: -0.01em;
    position: relative;
    z-index: 1;
  }
  .hero-title em { font-style: italic; color: var(--ink); }

  .hero-sub {
    font-family: var(--font-body);
    font-size: 0.68rem;
    color: var(--muted);
    letter-spacing: 0.08em;
    line-height: 1.9;
    max-width: 26ch;
    border-left: 1px solid var(--accent);
    padding-left: 1.5rem;
    position: relative;
    z-index: 1;
  }


  /* ── HEADER ── */
  header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 200;
    background: var(--panel);
    border-bottom: 1px solid var(--grid);
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    padding: 0 3rem;
    height: 54px;
  }

  .header-left { display: flex; align-items: center; gap: 2rem; }

  .initials {
    font-family: var(--font-body);
    font-size: 1.1rem; font-weight: 500;
    color: var(--ink); text-decoration: none;
    letter-spacing: 0.01em;
  }

  .header-status {
    font-family: var(--font-body);
    font-size: 0.58rem; color: var(--muted);
    letter-spacing: 0.12em;
    display: flex; align-items: center; gap: 0.5rem;
  }
  .header-status::before {
    content: ''; width: 5px; height: 5px;
    border-radius: 50%; background: var(--accent); display: block;
    animation: pulse 2.5s infinite;
  }
  @keyframes pulse { 0%,100%{opacity:1} 50%{opacity:.25} }

  .header-center {
    font-family: var(--font-body); font-size: 0.6rem;
    color: var(--muted); letter-spacing: 0.22em;
    text-transform: uppercase; text-align: center;
  }

  nav { display: flex; gap: 2.2rem; align-items: center; justify-content: flex-end; }
  nav a {
    font-family: var(--font-body); font-size: 0.8rem;
    letter-spacing: 0.18em; text-transform: uppercase;
    color: var(--ink); text-decoration: none;
    transition: color .2s; position: relative;
  }
  nav a::after {
    content: ''; position: absolute; bottom: -4px; left: 0;
    width: 0; height: 1px; background: var(--accent); transition: width .3s;
  }
  nav a:hover { color: var(--ink); }
  nav a:hover::after { width: 100%; }

  /* ── HERO ── */
  .hero {
    padding-top: 54px;
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .hero-left {
    background: var(--panel);
    display: flex; flex-direction: column;
    justify-content: space-between;
    padding: 7vh 4rem 6vh 5rem;
    position: relative; overflow: hidden;
  }
  /* blueprint grid */
  .hero-left::before {
    content: ''; position: absolute; inset: 0;
    background-image:
      linear-gradient(var(--grid-line) 1px, transparent 1px),
      linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
    background-size: 40px 40px;
  }
  /* right divider */
  .hero-left::after {
    content: ''; position: absolute; top: 0; right: 0; bottom: 0; width: 1px;
    background: linear-gradient(to bottom, transparent, var(--grid) 20%, var(--grid) 80%, transparent);
  }

  .name-label {
    font-family: var(--font-body); font-size: 0.696rem;
    color: var(--ink); letter-spacing: 0.28em;
    text-transform: uppercase; margin-bottom: 2.5rem;
    display: flex; align-items: center; gap: 1rem;
    position: relative; z-index: 1;
  }
  .name-label::before {
    content: ''; width: 1.5rem; height: 1px;
    background: var(--accent); display: block; flex-shrink: 0;
  }

  .full-name {
    font-family: var(--font-body);
    font-size: clamp(2.8rem, 5.5vw, 5.5rem);
    font-weight: 400; line-height: 0.95;
    letter-spacing: -0.02em;
    position: relative; z-index: 1;
  }
  .full-name .given {
    font-style: italic; color: var(--mid);
    font-size: 0.55em; display: block; margin-bottom: 0.2em;
  }
  .full-name .family { color: var(--ink); display: block; }

  .affil-row {
    display: flex; flex-direction: column; gap: 0.5rem;
    position: relative; z-index: 1;
  }
  .affil-item {
    font-family: var(--font-body); font-size: 0.868rem;
    color: var(--muted); letter-spacing: 0.08em;
    display: flex; align-items: center; gap: 0.75rem;
    transition: color .2s;
  }
  .affil-item::before {
    content: ''; width: 14px; height: 1px;
    background: var(--grid); flex-shrink: 0;
    transition: background .2s;
  }
  .affil-item.on { color: var(--ink); }
  .affil-item.on::before { background: var(--accent); }

  .hero-right {
    background: var(--paper);
    display: flex; flex-direction: column;
    justify-content: center;
    padding: 7vh 5rem 6vh 4.5rem;
    position: relative;
  }

  .coord {
    position: absolute; font-family: var(--font-body);
    font-size: 0.7rem; color: var(--muted); letter-spacing: 0.1em;
  }
  .coord-tl { top: 3rem; left: 5rem; }
  .coord-br { bottom: 3rem; right: 3rem; text-align: right; }

  .bio-statement {
    font-family: var(--font-body);
    font-size: clamp(1.1rem, 1.8vw, 1.4rem);
    font-weight: 400; line-height: 1.7;
    color: var(--ink); max-width: 50ch;
    margin-bottom: 2.5rem;
  }
  .bio-statement em { font-style: italic; color: var(--mid); }
  .bio-statement strong { font-weight: 600; color: var(--heading); }

  .domain-pills { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 3rem; }
  .pill {
    font-family: var(--font-body); font-size: 0.56rem;
    letter-spacing: 0.12em; text-transform: uppercase;
    color: var(--muted); border: 1px solid var(--rule);
    padding: 0.3rem 0.85rem; transition: border-color .2s, color .2s;
  }
  .pill:hover { border-color: var(--accent); color: var(--accent); }
  .pill.hi { border-color: var(--heading); color: var(--heading); }

  .cta-row { display: flex; gap: 1.5rem; align-items: center; flex-wrap: wrap; }

  .btn-pri {
    font-family: var(--font-body); font-size: 0.62rem;
    letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--ink); background: var(--panel);
    padding: .85rem 1.8rem; text-decoration: none;
    transition: background .2s;
  }
  .btn-pri:hover { background: var(--accent); }

  .btn-ghost {
    font-family: var(--font-body); font-size: 0.62rem;
    letter-spacing: 0.18em; text-transform: uppercase;
    color: var(--muted); text-decoration: none;
    display: flex; align-items: center; gap: .5rem;
    transition: color .2s;
  }
  .btn-ghost::after { content: '→'; transition: transform .2s; }
  .btn-ghost:hover { color: var(--ink); }
  .btn-ghost:hover::after { transform: translateX(4px); }

  /* ── SECTION SHARED ── */
  .sec {
    padding: 6rem 5rem;
    border-top: 1px solid var(--rule);
  }
  .sec.dark {
    background: var(--panel);
    border-top-color: var(--grid);
  }
  .sec.tinted { background: var(--paper-alt); }

  .sec-head {
    display: flex; align-items: baseline; gap: 1.5rem;
    margin-bottom: 4rem; padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--rule);
  }
  .sec.dark .sec-head { border-bottom-color: var(--grid); }

  .sec-num {
    font-family: var(--font-body); font-size: 1.5rem;
    color: var(--accent); letter-spacing: 0.2em; white-space: nowrap;
  }
  .sec-title {
    font-family: var(--font-body);
    font-size: clamp(1.6rem, 2.5vw, 2.3rem);
    font-weight: 400; letter-spacing: -.01em;
  }
  .sec.dark .sec-title { color: var(--ink); }

  .sec-rule {
    flex: 1; height: 1px; margin-left: auto;
    background: linear-gradient(to right, var(--rule), transparent);
  }
  .sec.dark .sec-rule { background: linear-gradient(to right, var(--grid), transparent); }

  .sec-count {
    font-family: var(--font-body); font-size: 1.1rem;
    color: var(--muted); letter-spacing: .1em;
  }
  .sec.dark .sec-count { color: var(--muted); }

  /* ── PUBLICATIONS ── */
  .pub-list { display: flex; flex-direction: column; }

  .pub-item {
    display: grid; grid-template-columns: 6rem 120px 1fr auto;
    gap: 2rem; padding: 2rem 0;
    border-top: 1px solid var(--rule);
    text-decoration: none; color: inherit;
    transition: background .15s;
    align-items: start;
  }
  .pub-item:hover { background: var(--paper-alt); margin: 0 -1rem; padding-left: 1rem; padding-right: 1rem; }

  .pub-year {
    font-family: var(--font-body); font-size: 1.2rem;
    color: var(--muted); letter-spacing: .08em; padding-top: .3rem;
  }

  .pub-type {
    font-family: var(--font-body); font-size: 0.65rem;
    color: var(--accent); letter-spacing: .2em;
    text-transform: uppercase; margin-bottom: .4rem;
    font-weight: bold;
  }
  .pub-title {
    font-family: var(--font-body); font-size: 1.15rem;
    font-weight: 500; line-height: 1.25;
    color: var(--heading); margin-bottom: .35rem;
  }
  .pub-venue {
    font-family: var(--font-body); font-style: italic;
    font-size: .88rem; color: var(--mid); margin-bottom: .6rem;
  }
  .pub-abstract {
    font-family: var(--font-body); font-size: .9rem;
    color: var(--mid); line-height: 1.65; max-width: 68ch;
      text-align: left;
  }
  .pub-tags {
    display: flex; gap: .4rem; flex-wrap: wrap; margin-top: .75rem;
  }
  .ptag {
    font-family: var(--font-body); font-size: .5rem;
    letter-spacing: .1em; text-transform: uppercase;
    color: var(--muted); border: 1px solid var(--rule);
    padding: .2rem .5rem; 
  }
  .pub-arrow {
    font-family: var(--font-body); font-size: .7rem;
    color: var(--rule); transition: color .2s; padding-top: .3rem;
  }
  .pub-item:hover .pub-arrow { color: var(--accent); }

  /* ── PROJECTS (card grid) ── */
  .proj-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 1.5rem;
  }

  .proj-card {
    padding: 2.5rem; border: 1px solid var(--rule);
    background: var(--card);
    text-decoration: none; color: inherit;
    display: flex; flex-direction: column;
    transition: border-color .2s, transform .25s;
    position: relative; overflow: hidden;
  }
  .proj-card::before {
    content: ''; position: absolute; top: 0; left: 0;
    width: 3px; height: 0; background: var(--accent);
    transition: height .3s;
  }
  .proj-card:hover { border-color: var(--accent); transform: translateY(-3px); }
  .proj-card:hover::before { height: 100%; }

  .pc-wide   { grid-column: span 7; }
  .pc-med    { grid-column: span 5; }
  .pc-third  { grid-column: span 4; }

  .pc-idx {
    font-family: var(--font-body); font-size: .54rem;
    color: var(--muted); letter-spacing: .2em; margin-bottom: 1.5rem;
  }
  .pc-title {
    font-family: var(--font-body); font-size: 1.45rem;
    font-weight: 400; line-height: 1.2;
    color: var(--heading); margin-bottom: .5rem;
  }
  .pc-sub {
    font-family: var(--font-body); font-size: .6rem;
    color: var(--accent); letter-spacing: .12em;
    text-transform: uppercase; margin-bottom: 1rem;
    text-align: left; font-weight: bold;
  }
  .pc-desc {
    font-family: var(--font-body); font-size: .93rem;
    color: var(--mid); line-height: 1.7; flex: 1;
    text-align: left;
  }
  .pc-specs {
    margin-top: 1.5rem; display: flex;
    flex-direction: column; gap: 0;
  }
  .spec-row {
    display: flex; justify-content: space-between;
    align-items: baseline;
    font-family: var(--font-body); font-size: .75rem;
    color: var(--muted); letter-spacing: .06em;
    border-top: 1px solid var(--rule); padding: .4rem 0 0;
  }
  .spec-row span:last-child { color: var(--mid); }

  .pc-link {
    font-family: var(--font-body); font-size: .58rem;
    color: var(--muted); letter-spacing: .12em;
    margin-top: 1.5rem; display: flex;
    align-items: center; gap: .4rem; transition: color .2s;
    font-weight: bold;
  }
  .pc-link::after { content: ' ↗'; }
  .proj-card:hover .pc-link { color: var(--accent); }

  /* ── COLLABORATIONS ── */
  .collab-grid {
    display: grid; grid-template-columns: repeat(3,1fr); gap: 1.5rem;
  }

  .collab-card {
    padding: 2rem; border: 1px solid var(--rule);
    background: var(--paper);
    transition: border-color .2s;
    display: flex; flex-direction: column;
  }
  .collab-card:hover { border-color: var(--heading); }

  .collab-type {
    font-family: var(--font-body); font-size: .54rem;
    color: var(--muted); letter-spacing: .22em;
    text-transform: uppercase; margin-bottom: 1rem;
    display: flex; align-items: center; gap: .6rem;
  }
  .collab-type::before {
    content: ''; width: 12px; height: 1px;
    background: var(--accent); display: block; flex-shrink: 0;
  }

  .collab-org {
    font-family: var(--font-body); font-size: 1.15rem;
    font-weight: 500; color: var(--heading); margin-bottom: .25rem;
  }
  .collab-role {
    font-family: var(--font-body); font-style: italic;
    font-size: .88rem; color: var(--mid); margin-bottom: 1rem;
  }
  .collab-desc {
    font-family: var(--font-body); font-size: .88rem;
    color: var(--mid); line-height: 1.65; flex: 1;
    text-align: left;
  }
  .collab-period {
    font-family: var(--font-body); font-size: .54rem;
    color: var(--muted); letter-spacing: .1em; margin-top: 1rem;
  }

  /* ── FRAMEWORK DARK BAND ── */
  .fw-body {
    display: grid; grid-template-columns: 3fr 500px 2fr; /* ← cambia 220px a piacere */
    gap: 3rem; align-items: center;
  }
  .fw-logo {
    display: flex;
    justify-content: center;
    align-items: center;
  }
  .fw-logo img {
    width: 100%;        /* occupa tutta la colonna definita sopra */
    max-width: 100%;
    height: auto;
    opacity: 1;      /* opzionale: si integra col dark background */
    filter: var(--framework-logo-filter); /* opzionale: rende il logo bianco su sfondo scuro */
  }
  .fw-text p {
    font-family: var(--font-body); font-size: 1.15rem;
    font-weight: 400; line-height: 2.0;
    color: var(--ink); margin-bottom: 1.5rem; max-width: 58ch;
    text-align: left;
  }
  .fw-text p strong { font-weight: 500; }
  .fw-text p em { font-style: italic; }

  .fw-aside {
    border-left: 1px solid var(--grid); padding-left: 2.5rem;
  }
  .fw-block { margin-bottom: 2.2rem; }
  .fw-label {
    font-family: var(--font-body); font-size: .75rem;
    color: var(--muted); letter-spacing: .25em;
    text-transform: uppercase; margin-bottom: .4rem;
  }
  .fw-value {
    font-family: var(--font-body); font-size: 1.05rem;
    color: var(--ink); font-weight: 400;
  }
  .fw-note {
    font-family: var(--font-body); font-size: .75rem;
    color: var(--muted); margin-top: .2rem; line-height: 1.5;
  }

  .fw-btn {
    display: inline-flex; align-items: center; gap: .75rem;
    font-family: var(--font-body); font-size: .75rem;
    letter-spacing: .18em; text-transform: uppercase;
    color: var(--ink); border: 1px solid var(--grid);
    padding: .85rem 1.8rem; text-decoration: none;
    margin-top: 1rem; transition: border-color .2s, color .2s;
  }
  .fw-btn:hover { border-color: var(--accent); color: var(--ink); }

  /* ── CONTACT ── */
  .contact-layout {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: 6rem; align-items: start;
  }

  .contact-statement {
    font-family: var(--font-body);
    font-size: clamp(1.15rem, 2vw, 1.5rem);
    font-weight: 400; line-height: 1.65;
    color: var(--ink); max-width: 38ch;
    text-align: left;
  }
  .contact-statement em { font-style: italic; color: var(--mid); }

  .clinks { display: flex; flex-direction: column; }

  .clink {
    display: flex; align-items: center;
    justify-content: space-between;
    padding: 1.2rem 0; border-bottom: 1px solid var(--rule);
    text-decoration: none; color: inherit;
    transition: color .2s;
  }
  .clink:first-child { border-top: 1px solid var(--rule); }
  .clink:hover { color: var(--accent); }

  .clink-label {
    font-family: var(--font-body); font-size: .56rem;
    color: var(--muted); letter-spacing: .18em;
    text-transform: uppercase; width: 7rem; flex-shrink: 0;
  }
  .clink-value {
    font-family: var(--font-body); font-size: .98rem;
    color: inherit; flex: 1;
  }
  .clink-arr {
    font-family: var(--font-body); font-size: .72rem;
    color: var(--rule); transition: color .2s, transform .2s;
  }
  .clink:hover .clink-arr { color: var(--accent); transform: translateX(4px); }

  /* ── FOOTER ── */
  footer {
    background: var(--paper);
    border-top: 2px solid var(--heading);
    padding: 3rem 5rem;
  }
  .foot-top {
    display: flex; align-items: flex-start;
    justify-content: space-between; gap: 3rem;
    flex-wrap: wrap; margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--rule);
  }
  .foot-logo { display: flex; align-items: center; gap: 1.25rem; text-decoration: none; }
  .foot-logo-mark {
    width: 44px; height: 44px;
    border: 1.5px solid var(--heading);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
  }
  .foot-logo-name {
    font-family: var(--font-body); font-size: 2.1rem;
    font-weight: 500; color: var(--ink);
    letter-spacing: .01em; display: block; line-height: 1.1;
  }
  .foot-logo-sub {
    font-family: var(--font-body); font-size: 1.08rem;
    color: var(--muted); letter-spacing: .15em; text-transform: uppercase;
  }
  .foot-cols { display: flex; gap: 4rem; flex-wrap: wrap; }
  .foot-col-label {
    font-family: var(--font-body); font-size: 1.08rem;
    color: var(--accent); letter-spacing: .22em;
    text-transform: uppercase; margin-bottom: .75rem;
  }
  .foot-col-items { display: flex; flex-direction: column; gap: .35rem; }
  .foot-col-items span,
  .foot-col-items a {
    font-family: var(--font-body); font-size: 1.2rem;
    color: var(--mid); letter-spacing: .06em;
    text-decoration: none; line-height: 1.5; transition: color .2s;
  }
  .foot-col-items a:hover { color: var(--heading); }
  .foot-bottom {
    display: flex; align-items: center;
    justify-content: space-between; gap: 2rem; flex-wrap: wrap;
  }
  .foot-copy {
    font-family: var(--font-body); font-size: .88rem;
    color: var(--muted); letter-spacing: .1em;
  }
  .foot-copy a { color: var(--muted); text-decoration: none; }
  .foot-copy a:hover { color: var(--mid); }
  .foot-license {
    color: var(--muted);
    display: flex; align-items: center; gap: .75rem;
  }
  .cc-badge {
    display: flex; align-items: center;
    transition: opacity .2s;
  }
  .cc-badge:hover { opacity: .75; }
  .cc-badge img { display: block; height: 1.7rem; width: auto; }
  .foot-license::before { content: ''; display: block; width: 1.5rem; height: 1px; background: var(--rule); }
  /* logo svg in header */
  .header-logo {
    display: flex; align-items: center; gap: 1rem;
    text-decoration: none; flex-shrink: 0;
    height: 100%;
  }
  .header-logo-svg {
    height: 36px; width: auto;
    display: block;
    opacity: 0.9; transition: opacity .2s;
  }
  .header-logo:hover .header-logo-svg { opacity: 1; }
  .header-logo > div {
    display: flex; flex-direction: column; justify-content: center;
    height: 36px;
  }
  .header-logo-name {
    font-family: var(--font-body); font-size: 1rem;
    font-weight: 500; color: var(--ink);
    letter-spacing: .01em; line-height: 1;
    white-space: nowrap;
  }
  .header-logo-sub {
    font-family: var(--font-body); font-size: .5rem;
    color: var(--muted); letter-spacing: .15em;
    text-transform: uppercase; display: block;
    margin-top: .15rem;
  }
  .pub-updated {
    font-family: var(--font-body); font-size: .65rem;
    color: var(--muted); letter-spacing: .1em;
    margin-top: .5rem; display: flex; align-items: center; gap: .4rem;
  }
  .pub-updated::before { content: '↻'; font-size: .65rem; color: var(--accent); }

  /* ── ANIMATIONS ── */
  @keyframes up {
    from { opacity:0; transform:translateY(16px); }
    to   { opacity:1; transform:translateY(0); }
  }
  .full-name       { animation: up 1s ease both; }
  .affil-row       { animation: up 1s ease .1s both; }
  .bio-statement   { animation: up 1s ease .2s both; }
  .domain-pills    { animation: up 1s ease .32s both; }
  .cta-row         { animation: up 1s ease .42s both; }

  /* ── RESPONSIVE ── */
  @media (max-width: 1024px) {
    header { grid-template-columns: 1fr auto; padding: 0 1.5rem; }
    .header-center { display: none; }
    .hero { grid-template-columns: 1fr; }
    .hero-left { padding: 5rem 2rem 3rem; min-height: 55vh; }
    .hero-right { padding: 3rem 2rem 4rem; }
    .sec { padding: 4rem 2rem; }
    .proj-grid { grid-template-columns: 1fr 1fr; }
    .pc-wide,.pc-med,.pc-third { grid-column: span 2; }
    .fw-body { grid-template-columns: 1fr; gap: 3rem; }
    .collab-grid { grid-template-columns: 1fr 1fr; }
    .contact-layout { grid-template-columns: 1fr; gap: 3rem; }
    footer { padding: 2rem; flex-direction: column; }
    .foot-r { text-align: left; }
  }
  @media (max-width: 640px) {
    .proj-grid { grid-template-columns: 1fr; }
    .pc-wide,.pc-med,.pc-third { grid-column: span 1; }
    .collab-grid { grid-template-columns: 1fr; }
    nav { gap: 1.2rem; }
    nav a { font-size: .56rem; }
    .pub-item { grid-template-columns: 3rem 1fr; } .pub-img { display: none; }
    .pub-arrow { display: none; }
  }

  @media (max-width: 640px) {

    /* ───────── HEADER ───────── */

    header {
      height: 48px;
      padding: 0 .9rem;
      grid-template-columns: auto 1fr;
      gap: .75rem;
    }

    .header-logo-svg {
      height: 28px;
    }

    .header-logo-name {
      display: none;
    }

    nav {
      gap: .75rem;
      min-width: 0;
    }

    nav a {
      font-size: .48rem;
      letter-spacing: .08em;
    }


    /* ───────── HERO ───────── */

    .hero {
      padding-top: 48px;
      min-height: auto;
      display: block;
    }

    .hero-left {
      min-height: auto;
      padding: 2.75rem 1.25rem 2rem;

      justify-content: flex-start;
      gap: 1.75rem;
    }

    .name-label {
      font-size: .56rem;
      letter-spacing: .16em;
      margin-bottom: .75rem;
      gap: .6rem;
    }

    .hero-title {
      font-size: clamp(2.15rem, 10vw, 2.8rem);
      line-height: 1.02;
      margin-bottom: 0;
    }

    .affil-row {
      gap: .4rem;
    }

    .affil-item {
      font-size: .68rem;
      line-height: 1.45;
      align-items: flex-start;
    }


    /* ───────── HERO RIGHT ───────── */

    .hero-right {
      padding: 2rem 1.25rem 2.25rem;
      justify-content: flex-start;
    }

    .coord-tl {
      position: static;
      margin-bottom: 1.5rem;

      font-size: .48rem;
      line-height: 1.5;
    }

    .bio-statement {
      max-width: none;
      font-size: 1.05rem;
      line-height: 1.5;
      margin-bottom: 1.4rem;
    }

    .domain-pills {
      gap: .4rem;
      margin-bottom: 1.6rem;
    }

    .pill {
      font-size: .47rem;
      padding: .25rem .55rem;
      letter-spacing: .08em;
    }

    .cta-row {
      gap: .8rem 1rem;
    }

    .btn-pri,
    .btn-ghost {
      font-size: .53rem;
    }

    /*
    * Fondamentale:
    * su desktop può essere absolute,
    * su mobile deve rientrare nel normale flow.
    */
    .coord-br {
      position: static;
      align-self: flex-end;

      margin-top: 1.75rem;

      font-size: .48rem;
      line-height: 1.45;
      text-align: right;
    }

    .coord-br img {
      width: 70px;
      height: auto;
    }


    /* ───────── SECTIONS ───────── */

    .sec {
      padding: 3rem 1.25rem;
    }

    .sec-head {
      display: grid;
      grid-template-columns: auto minmax(0, 1fr);

      column-gap: .8rem;
      row-gap: .3rem;

      align-items: baseline;

      margin-bottom: 2rem;
      padding-bottom: 1rem;
    }

    .sec-num {
      font-size: .85rem;
    }

    .sec-title {
      font-size: 1.4rem;
      line-height: 1.1;
    }

    .sec-rule {
      display: none;
    }

    .sec-count {
      grid-column: 2;
      font-size: .58rem;
    }


    /* ───────── RESEARCH / REPORTS ───────── */

    .pub-item {
      grid-template-columns: 1fr;
      gap: .45rem;

      padding: 1.6rem 0;
    }

    .pub-year {
      font-size: .7rem;
      padding-top: 0;
      margin-bottom: .15rem;
    }

    .pub-img {
      display: none;
    }

    .pub-arrow {
      display: none;
    }

    .pub-title {
      font-size: 1.05rem;
      line-height: 1.3;
    }

    .pub-type {
      font-size: .55rem;
      line-height: 1.5;
      letter-spacing: .13em;
    }

    .pub-venue {
      font-size: .82rem;
      line-height: 1.45;
    }

    .pub-abstract {
      max-width: none;

      font-size: .86rem;
      line-height: 1.55;

      /* justify su 350px è un crimine tipografico */
      text-align: left;
    }

    .pub-updated {
      font-size: .52rem;
      line-height: 1.5;
    }

    .pub-tags {
      gap: .3rem;
      margin-top: .65rem;
    }

    .ptag {
      font-size: .44rem;
      padding: .18rem .4rem;
    }
  }

  /* footer mark large */
  .foot-mark-wrap {
    display: flex; flex-direction: column; gap: 1.75rem;
  }
  .foot-mark-large {
    width: clamp(240px, 28vw, 340px);
    max-width: 100%;
    height: auto;
    display: block;
  }

  .foot-mark-label {
    display: flex;
    align-items: center;
    gap: 1.5rem;
  }

  .foot-logo-img {
    height: 60px; /* You can adjust the height based on the image aspect ratio */
    width: auto;
    display: block;
  }

  .foot-logo-text {
    display: flex;
    flex-direction: column;
  }
  
  /* pub image placeholder */
  .pub-img {
    width: 120px; flex-shrink: 0;
    display: flex; flex-direction: column;
    gap: 0;
  }
  .pub-img-box {
    width: 120px; height: 80px;
    border: 1px dashed var(--rule);
    background: var(--paper-alt);
    display: flex; align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 0.3rem;
  }
  .pub-img-icon {
    font-family: var(--font-body); font-size: .52rem;
    color: var(--muted); letter-spacing: .15em;
    text-transform: uppercase; text-align: center;
    line-height: 1.5;
  }
  .pub-item { align-items: start; }

/* ── Futura identity / final component overrides ── */
html { scroll-padding-top: calc(var(--header-height) + 20px); }
body { font-weight: 400; }
header { background: var(--header); height: var(--header-height); grid-template-columns: minmax(0,1fr) auto auto; gap: 1.25rem; }
.header-center { display: none; }
.header-left { min-width: 0; }
.header-logo { gap: .75rem; }
.header-logo-name { font-weight: 700; color: var(--heading); font-size: 1rem; }
.brand-mark { display: inline-block; flex: none; width: 38px; height: 38px; background-color: var(--brand); -webkit-mask: url("../../content/Logo_GND.png") center / contain no-repeat; mask: url("../../content/Logo_GND.png") center / contain no-repeat; }
.coord .brand-mark { width: 76px; height: 76px; }
.foot-mark-label .brand-mark { width: 60px; height: 60px; }
nav { gap: clamp(.8rem,2vw,2rem); }
nav a { color: var(--muted); font-size: .78rem; font-weight: 600; letter-spacing: .08em; }
nav a:hover { color: var(--accent); }
nav a::after { background: var(--accent-line); height: 2px; }
.theme-controls { display: flex; align-items: center; gap: .4rem; }
.theme-controls[hidden], .theme-reset[hidden] { display: none !important; }
.theme-toggle, .theme-reset { display: inline-flex; align-items: center; justify-content: center; gap: .45rem; min-height: 40px; padding: .45rem .75rem; border: 1px solid var(--rule); border-radius: 3px; background: var(--paper); color: var(--ink); font: 600 .75rem/1.2 var(--font-body); cursor: pointer; white-space: nowrap; }
.theme-toggle:hover, .theme-reset:hover { border-color: var(--accent); color: var(--accent); }
.theme-toggle svg { width: 17px; height: 17px; flex: none; }
.theme-toggle svg[hidden] { display: none; }
.theme-reset { padding-inline: .55rem; }
:where(a,button):focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; }
.hero { padding-top: var(--header-height); }
.hero-left { border-bottom: 3px solid var(--accent-line); }
.hero-title { color: var(--heading); font-family: var(--font-display); font-weight: 700; letter-spacing: -.035em; font-size: clamp(2.5rem,4.6vw,5rem); line-height: 1.08; }
.hero-title em { font-style: normal; color: var(--accent); }
.full-name, .sec-title, .pub-title, .pc-title, .collab-org, .fw-value, .foot-logo-name { font-family: var(--font-display); font-weight: 700; }
.bio-statement strong, .fw-text p strong { font-weight: 700; color: var(--heading); }
.name-label { color: var(--muted); font-weight: 700; letter-spacing: .16em; }
.name-label::before, .affil-item.on::before, .collab-type::before { background: var(--accent-line); height: 3px; }
.affil-item { color: var(--muted); font-size: .85rem; }
.affil-item.on { color: var(--ink); }
.sec-title { color: var(--heading); }
.sec-num { font-weight: 700; }
.sec.dark { background: var(--panel); }
.btn-pri { background: var(--button-bg); color: var(--button-fg); font-weight: 700; letter-spacing: .1em; }
.btn-pri:hover { background: var(--button-hover); color: var(--button-fg); }
.btn-ghost, .fw-btn { font-weight: 600; }
.pill, .ptag { font-size: .7rem; letter-spacing: .055em; }
.pill.hi { color: var(--accent); border-color: var(--accent); }
.pub-title, .pc-title, .collab-org { color: var(--heading); }
.pub-type, .pc-sub, .collab-type, .fw-label { font-weight: 700; letter-spacing: .09em; font-size: .76rem; color: var(--accent); }
.pub-abstract, .pc-desc, .collab-desc { font-size: .98rem; line-height: 1.65; }
.pub-updated, .pc-idx, .pc-link, .collab-period { font-size: .72rem; }
.pub-img { display: flex; justify-content: center; align-items: center; padding: .6rem; background: var(--logo-surface); border: 1px solid var(--rule); min-height: 100px; }
.pub-img img { max-width: 100%; max-height: 110px; object-fit: contain; }
.proj-card { background: var(--card); }
.proj-card::before { background: var(--accent-line); }
.spec-row { gap: 1rem; }
.spec-row span:last-child { text-align: right; }
.fw-body { grid-template-columns: minmax(0,3fr) minmax(0,2fr) minmax(0,2fr); gap: 2.5rem; }
.fw-text p { font-size: 1rem; line-height: 1.7; }
.fw-btn:hover { color: var(--accent); }
.clink-label { font-size: .72rem; }
.clink-value { overflow-wrap: anywhere; min-width: 0; }
.foot-logo-sub { font-size: .8rem; }
footer { border-top: 3px solid var(--accent-line); }
.foot-license img { background: #fff; padding: 2px; border-radius: 2px; }
@media (max-width: 1024px) {
  .fw-body { grid-template-columns: 1fr; }
  .fw-logo img { max-width: 280px; }
  .fw-aside { padding-left: 1.5rem; }
  header { grid-template-columns: minmax(0,1fr) auto auto; gap: .8rem; }
  .hero-left { min-height: 48vh; }
  .hero-right { padding-top: 5rem; padding-bottom: 8rem; }
}
@media (max-width: 900px) {
  :root { --header-height: 108px; }
  header { display: grid; grid-template-columns: minmax(0,1fr) auto; grid-template-rows: 57px 51px; height: var(--header-height); gap: 0 .5rem; padding: 0 1rem; }
  .header-logo-name { display: block; font-size: .9rem; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
  .header-logo > div { min-width: 0; }
  .header-logo { min-width: 0; }
  .header-logo .brand-mark { width: 32px; height: 32px; }
  .theme-controls { grid-column: 2; grid-row: 1; }
  nav { grid-column: 1 / -1; grid-row: 2; justify-content: space-between; gap: .4rem; border-top: 1px solid var(--rule); height: 100%; }
  nav a { font-size: clamp(.62rem,2vw,.78rem); letter-spacing: .035em; }
  .theme-toggle, .theme-reset { min-height: 36px; padding: .35rem .55rem; }
  .hero { padding-top: var(--header-height); }
  .hero-left { min-height: auto; padding: 2.5rem 1.25rem; gap: 1.6rem; }
  .hero-title { font-size: clamp(2.2rem,8vw,3.6rem); margin-bottom: 0; }
  .hero-right { padding: 2rem 1.25rem; }
  .coord-tl, .coord-br { position: static; }
  .coord-tl { margin-bottom: 1.2rem; }
  .coord-br { align-self: flex-end; margin-top: 1.5rem; text-align: right; }
  .pub-img { display: none; }
  .pub-item { grid-template-columns: 1fr; gap: .6rem; }
  .pub-arrow { display: none; }
  .proj-card, .collab-card { padding: 1.5rem; }
  .fw-aside { padding-left: 1rem; }
  .clink-label { width: 5rem; }
  .foot-logo-name { font-size: 1.45rem; }
}
@media (max-width: 380px) { .theme-toggle [data-theme-label] { display: none; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
@media print {
  :root, :root:not([data-theme]), :root[data-theme="dark"] { color-scheme: light; --paper: #fff; --paper-alt: #fff; --panel: #fff; --header: #fff; --card: #fff; --ink: #080C1A; --heading: #080C1A; --accent: #67509B; --accent-line: #67509B; --mid: #30364A; --muted: #505773; --rule: #D6D4E0; --grid: #D6D4E0; --grid-line: transparent; --button-bg: #fff; --button-fg: #080C1A; --brand: #67509B; --framework-logo-filter: brightness(0); }
  header { position: static; height: auto; padding: .8rem 0; }
  nav, .theme-controls, .cta-row { display: none !important; }
  .hero { padding-top: 0; min-height: auto; }
  .hero-left, .hero-right, .sec, footer { padding: 1rem 0; }
  .hero-left::before, .hero-left::after { display: none; }
  .proj-card, .collab-card, .pub-item { break-inside: avoid; }
}
