/* ==========================================================================
   Landing — "Lightbox": sala refertazione di notte
   ========================================================================== */

.landing { position: relative; }
.landing::before {
	/* grana pellicola */
	content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .05;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.landing > * { position: relative; z-index: 1; }

/* Indicatore di avanzamento "slice" */
.slice-indicator { position: fixed; right: 18px; top: 50%; z-index: 40; display: flex; flex-direction: column; align-items: center; gap: 10px; transform: translateY(-50%); color: var(--muted); font-size: 9px; writing-mode: vertical-rl; }
.slice-track { position: relative; width: 1px; height: 140px; background: var(--border); }
.slice-thumb { position: absolute; left: -2px; top: 0; width: 5px; height: 18px; background: var(--rl-cyan); box-shadow: 0 0 10px var(--rl-cyan); }

/* --------------------------------------------------------------------------
   Sezioni
   -------------------------------------------------------------------------- */
.section { padding: clamp(72px, 9vw, 120px) 0; }
.section + .section { padding-top: clamp(16px, 3vw, 40px); }
.section-head { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 8px 24px; padding-bottom: 22px; margin-bottom: 48px; border-bottom: 1px solid var(--border); }
.section-kicker { grid-column: 1 / -1; margin: 0; color: var(--rl-cyan); font-size: 11px; }
.section-heading { margin: 0; font-size: clamp(32px, 4.4vw, 52px); font-weight: 600; letter-spacing: -.03em; }
.section-aside { color: var(--muted); font-size: 11px; }
a.section-aside { color: var(--rl-cyan); }
.chip { display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px; border: 1px solid var(--border); border-radius: 999px; background: rgba(92, 225, 230, .04); color: var(--rl-cyan); font-size: 11px; }

[data-reveal] { will-change: transform, opacity, clip-path; }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */
.hero { position: relative; display: flex; align-items: center; min-height: 100svh; padding: calc(var(--header-h) + 40px) 0 96px; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.hero-grid {
	position: absolute; inset: -10%;
	background-image: linear-gradient(rgba(92, 225, 230, .06) 1px, transparent 1px), linear-gradient(90deg, rgba(92, 225, 230, .06) 1px, transparent 1px);
	background-size: 56px 56px;
	mask-image: radial-gradient(70% 60% at 65% 45%, #000 20%, transparent 80%);
}
.hero-bg::after { content: ""; position: absolute; inset: 0; background: radial-gradient(50% 50% at 70% 45%, rgba(47, 123, 255, .16), transparent 70%), radial-gradient(30% 35% at 20% 80%, rgba(92, 225, 230, .08), transparent 70%); }
.hero-particles { position: absolute; inset: 0; width: 100%; height: 100%; }

.hero-inner { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: center; gap: clamp(32px, 5vw, 80px); }
.hero-hello { margin: 26px 0 6px; color: var(--heading); font-size: clamp(15px, 1.5vw, 19px); letter-spacing: .02em; text-transform: none; }
.hero-title { margin: 0; font-size: clamp(46px, 7.4vw, 104px); font-weight: 600; line-height: .98; letter-spacing: -.045em; }
.hero-prefix { display: block; }
.hero-rotator { display: block; min-height: 2em; }
.hero-rotator-text { padding-bottom: .06em; }
.caret { display: inline-block; width: .06em; height: .82em; margin-left: .06em; vertical-align: -.04em; background: var(--rl-cyan); box-shadow: 0 0 12px var(--rl-cyan); animation: rl-blink 1s steps(1) infinite; }
@keyframes rl-blink { 50% { opacity: 0; } }
.hero-roles { margin: 18px 0 0; color: var(--muted); font-size: 11px; }
.hero-text { max-width: 430px; margin: 22px 0 0; font-size: clamp(16px, 1.3vw, 18px); line-height: 1.65; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }

/* Il visual sborda a sinistra nella colonna del testo: il diafanoscopio arriva a lambire il titolo rotante */
.hero-visual { position: relative; aspect-ratio: 1.12; width: calc(100% + clamp(40px, 16vw, 280px)); max-width: none; margin-left: calc(-1 * clamp(40px, 16vw, 280px)); justify-self: end; container-type: inline-size; }
.hero-copy { position: relative; z-index: 3; }

@keyframes rl-scan { 0% { top: 0; } 50% { top: calc(100% - 2px); } 100% { top: 0; } }

/* --- Diafanoscopio ------------------------------------------------------ */
.lightbox { position: absolute; left: 0; top: 9%; width: 82%; }
.lightbox-frame {
	position: relative; padding: 14px 14px 0; border-radius: 10px;
	background: linear-gradient(160deg, #2b323c 0%, #161b22 55%, #0f1318 100%);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 40px 80px -30px rgba(0, 0, 0, .9);
}
/* alone di luce attorno al diafanoscopio, sincronizzato con la pellicola */
.lightbox-frame::before {
	content: ""; position: absolute; inset: -40px; z-index: -1; border-radius: 40px;
	background: radial-gradient(closest-side, rgba(190, 232, 255, .32), rgba(92, 225, 230, .1) 60%, transparent);
	animation: rl-viewbox-halo 7s ease-in-out infinite;
}
.lightbox-panel {
	position: relative; aspect-ratio: 1.22; padding: 6% 7% 7%; overflow: hidden; border-radius: 3px;
	background: radial-gradient(120% 100% at 50% 40%, #f4fbff 0%, #d9eefb 55%, #b8d9ee 100%);
	animation: rl-viewbox-panel 7s ease-in-out infinite;
}
/* righe dei tubi fluorescenti dietro il pannello opalino */
.lightbox-panel::before {
	content: ""; position: absolute; inset: 0; opacity: .25; pointer-events: none;
	background: repeating-linear-gradient(90deg, transparent 0 22%, rgba(255, 255, 255, .9) 24%, transparent 27% 33%);
	filter: blur(14px);
}
.lightbox-film {
	position: relative; z-index: 1; width: 100%; height: 100%; object-fit: cover; border-radius: 2px;
	box-shadow: 0 0 0 1px rgba(0, 0, 0, .25), 0 6px 18px rgba(0, 30, 60, .25);
	transform: rotate(-.6deg);
	animation: rl-viewbox-film 7s ease-in-out infinite;
}
.lightbox-glow { position: absolute; inset: 0; z-index: 2; pointer-events: none; mix-blend-mode: screen; background: radial-gradient(70% 60% at 50% 45%, rgba(200, 240, 255, .35), transparent 70%); animation: rl-viewbox-glow 7s ease-in-out infinite; }
.film-clip { position: absolute; top: 3%; z-index: 3; width: 9%; height: 7%; border-radius: 2px 2px 4px 4px; background: linear-gradient(180deg, #e7ebef, #9aa4ad 60%, #6f7881); box-shadow: 0 2px 4px rgba(0, 0, 0, .35); }
.film-clip--l { left: 22%; }
.film-clip--r { right: 22%; }
.film-label { position: absolute; z-index: 3; left: 9%; bottom: 9%; color: rgba(255, 255, 255, .8); font-size: 8.5px; text-shadow: 0 0 4px #000; }
.film-marker { position: absolute; z-index: 3; right: 9%; top: 12%; color: rgba(255, 255, 255, .85); font-size: 12px; font-weight: 600; text-shadow: 0 0 4px #000; }
.lightbox-base { display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 4px; color: #6f7a86; font-size: 8.5px; }
.lightbox-switch { width: 22px; height: 10px; border-radius: 6px; background: #0b0e12; box-shadow: inset 0 1px 2px #000; position: relative; }
.lightbox-switch::after { content: ""; position: absolute; right: 2px; top: 2px; width: 6px; height: 6px; border-radius: 50%; background: #9aa4ad; }
.lightbox-led { margin-left: auto; width: 6px; height: 6px; border-radius: 50%; background: var(--rl-cyan); box-shadow: 0 0 8px var(--rl-cyan); animation: rl-blink 2.4s steps(1) infinite; }

/* Respiro lento della retroilluminazione + due sfarfallii da neon (40% e 82%) */
@keyframes rl-viewbox-film {
	0%, 100% { filter: brightness(.78) contrast(1.12); }
	30%      { filter: brightness(1.08) contrast(1.02); }
	40%      { filter: brightness(1.12) contrast(1); }
	40.8%    { filter: brightness(.55) contrast(1.2); }
	41.4%    { filter: brightness(1.05) contrast(1); }
	42%      { filter: brightness(.7) contrast(1.15); }
	43%      { filter: brightness(1.1) contrast(1); }
	65%      { filter: brightness(.95) contrast(1.05); }
	82%      { filter: brightness(.88) contrast(1.08); }
	82.6%    { filter: brightness(.6) contrast(1.2); }
	83.2%    { filter: brightness(.9) contrast(1.06); }
}
@keyframes rl-viewbox-panel {
	0%, 100% { filter: brightness(.82); }
	40%      { filter: brightness(1.1); }
	40.8%    { filter: brightness(.6); }
	41.4%    { filter: brightness(1.05); }
	42%      { filter: brightness(.72); }
	43%      { filter: brightness(1.08); }
	82.6%    { filter: brightness(.65); }
	83.2%    { filter: brightness(.9); }
}
@keyframes rl-viewbox-halo {
	0%, 100% { opacity: .45; }
	40%      { opacity: 1; }
	40.8%    { opacity: .2; }
	41.4%    { opacity: .9; }
	42%      { opacity: .35; }
	43%      { opacity: 1; }
	82.6%    { opacity: .3; }
	83.2%    { opacity: .7; }
}
@keyframes rl-viewbox-glow {
	0%, 100% { opacity: .2; }
	40%      { opacity: .7; }
	40.8%    { opacity: 0; }
	43%      { opacity: .6; }
}

/* --- Tesserino "Hello! my name is" ------------------------------------- */
.badge-wrap { position: absolute; right: 0; top: 24%; width: 31%; z-index: 2; }
.badge-inner-drop { position: relative; }
.lanyard {
	position: absolute; left: 50%; bottom: calc(100% - 6px); width: 22px; height: 150px; transform: translateX(-50%);
	display: flex; justify-content: center; overflow: hidden;
	background: linear-gradient(90deg, #005a96, var(--rl-brand) 30%, var(--rl-brand) 70%, #005a96);
	box-shadow: inset 2px 0 0 rgba(255, 255, 255, .14), inset -2px 0 0 rgba(0, 0, 0, .25);
	mask-image: linear-gradient(transparent, #000 45%);
}
/* Scritta stampata sul laccetto, letta dal basso verso l'alto come sui cordini veri */
.lanyard-text {
	align-self: flex-end; padding-top: 16px; white-space: nowrap; /* ruotato di 180°: il padding-top finisce in basso, sopra il moschettone */
	writing-mode: vertical-rl; transform: rotate(180deg);
	font: 700 10px/22px var(--font-head); letter-spacing: .22em; color: #fff;
	text-shadow: 0 0 1px rgba(0, 0, 0, .3);
}
.lanyard::after { /* moschettone */
	content: ""; position: absolute; left: 50%; bottom: -12px; width: 16px; height: 22px; transform: translateX(-50%);
	border: 3px solid #b9c2cb; border-radius: 8px 8px 10px 10px; background: transparent;
}
.badge {
	position: relative; margin: 0; overflow: hidden; border-radius: 14px; background: #fbfcfd; color: #0a0e14;
	box-shadow: 0 1px 0 rgba(255, 255, 255, .6) inset, 0 30px 60px -18px rgba(0, 0, 0, .85), 0 0 0 1px rgba(0, 0, 0, .06);
	transform-origin: 50% -40px; animation: rl-swing 6.5s ease-in-out infinite;
}
/* riflesso della plastica */
.badge::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(115deg, transparent 35%, rgba(255, 255, 255, .55) 45%, transparent 55%); transform: translateX(-60%); animation: rl-sheen 6.5s ease-in-out infinite; }
@keyframes rl-swing { 0%, 100% { transform: rotate(-3deg); } 50% { transform: rotate(2.5deg); } }
@keyframes rl-sheen { 0%, 100% { transform: translateX(-70%); } 50% { transform: translateX(70%); } }
.badge-hole { position: absolute; top: 9px; left: 50%; z-index: 2; width: 34px; height: 8px; transform: translateX(-50%); border-radius: 6px; background: #0a0e14; box-shadow: inset 0 1px 2px rgba(0, 0, 0, .6); }
/* Misure in cqw (= % della larghezza del visual): il tesserino scala in proporzione su ogni schermo */
.badge-head { display: flex; flex-direction: column; align-items: center; padding: clamp(18px, 3.4cqw, 28px) 8px clamp(8px, 1.6cqw, 12px); background: linear-gradient(135deg, var(--rl-brand), var(--rl-blue)); color: #fff; text-align: center; }
.badge-hello { font: 700 clamp(18px, 4.6cqw, 40px)/1 var(--font-head); letter-spacing: -.02em; }
.badge-myname { margin-top: 3px; font-size: clamp(7px, 1.25cqw, 10px); letter-spacing: .18em; opacity: .9; }
.badge-photo { margin: clamp(8px, 1.8cqw, 14px) clamp(8px, 1.8cqw, 14px) 0; aspect-ratio: 4 / 5; overflow: hidden; border-radius: 8px; background: linear-gradient(160deg, #e8f2f9, #cfe2ef); }
.badge-photo img { width: 100%; height: 100%; object-fit: cover; }
.badge-photo-empty { display: grid; place-items: center; align-content: center; gap: 10px; height: 100%; padding: 12px; text-align: center; }
.badge-photo-empty img { width: 46%; height: auto; opacity: .85; }
.badge-photo-empty .mono { color: #5b6b78; font-size: 8.5px; line-height: 1.4; }
.badge-body { display: flex; flex-direction: column; align-items: center; padding: clamp(4px, 1cqw, 8px) 8px 2px; text-align: center; }
.badge-name { font: 700 clamp(24px, 6cqw, 50px)/1 "Caveat", cursive; color: #0a0e14; transform: rotate(-2deg); }
.badge-role { margin-top: 4px; color: var(--rl-brand); font-size: clamp(7px, 1.15cqw, 9px); letter-spacing: .06em; }
.badge-foot { display: flex; align-items: center; gap: 8px; margin: clamp(6px, 1.3cqw, 10px) clamp(8px, 1.8cqw, 14px) clamp(8px, 1.8cqw, 14px); padding-top: clamp(6px, 1.3cqw, 10px); border-top: 1px dashed #d4dde4; }
.badge-barcode { flex: none; width: 46%; height: clamp(16px, 3.2cqw, 26px); background: repeating-linear-gradient(90deg, #0a0e14 0 2px, transparent 2px 4px, #0a0e14 4px 5px, transparent 5px 8px, #0a0e14 8px 11px, transparent 11px 12px); }
.badge-id { display: flex; flex-direction: column; gap: 2px; color: #5b6b78; font-size: 7.5px; line-height: 1.2; }
.badge-id span:first-child { color: #0a0e14; }

.scroll-hint { position: absolute; left: 50%; bottom: 28px; display: flex; flex-direction: column; align-items: center; gap: 10px; transform: translateX(-50%); color: var(--muted); font-size: 10px; }
.scroll-mouse { width: 18px; height: 28px; border: 1px solid var(--muted); border-radius: 10px; position: relative; }
.scroll-mouse::after { content: ""; position: absolute; left: 50%; top: 6px; width: 3px; height: 6px; margin-left: -1.5px; border-radius: 2px; background: var(--rl-cyan); animation: rl-wheel 1.6s ease-in-out infinite; }
@keyframes rl-wheel { 60% { transform: translateY(8px); opacity: 0; } 100% { opacity: 0; } }

/* --------------------------------------------------------------------------
   Progetti in evidenza
   -------------------------------------------------------------------------- */
.project-feature {
	--acc: var(--rl-cyan);
	position: relative; display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); align-items: center; gap: clamp(28px, 4vw, 64px);
	padding: clamp(24px, 3.5vw, 48px); margin-bottom: 56px; border: 1px solid var(--border); border-radius: 4px;
	background: linear-gradient(160deg, rgba(17, 24, 33, .9), rgba(10, 14, 20, .6));
}
.project-feature .vp-corner { border-color: var(--acc); }
.project-feature.is-reversed .project-copy { order: 2; }
.accent-blue { --acc: var(--rl-blue); }
.accent-coral { --acc: var(--rl-coral); }
.project-label { display: flex; align-items: center; gap: 10px; margin: 0 0 18px; color: var(--acc); font-size: 11px; }
.project-label .dot { background: var(--acc); box-shadow: 0 0 10px var(--acc); }
.project-title { margin: 0; font-size: clamp(36px, 4.4vw, 56px); font-weight: 600; letter-spacing: -.035em; }
.project-tagline { margin: 8px 0 22px; color: var(--acc); font-size: 13px; text-transform: none; letter-spacing: .02em; }
.project-text { color: var(--text); font-size: 16px; }
.project-text p { margin: 0; }
.project-feature .badges { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 22px 0 0; padding: 0; }
.project-feature .badges li { padding: 5px 10px; border: 1px solid var(--border); border-radius: 3px; background: rgba(255, 255, 255, .02); color: var(--text); font-size: 10px; }
.project-feature .badges li:first-child { border-color: color-mix(in srgb, var(--acc) 50%, transparent); color: var(--acc); }
.project-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.accent-coral .btn-primary { background: linear-gradient(90deg, var(--rl-coral), #ff8f5e); color: #2a0b03; }
.accent-blue .btn-primary { background: linear-gradient(90deg, var(--rl-cyan), var(--rl-blue)); }

.project-media {
	position: relative; display: block; border: 1px solid var(--border); border-radius: 6px; overflow: hidden;
	background: #0d141c; transform-style: preserve-3d; transition: box-shadow .4s;
	box-shadow: 0 40px 80px -40px rgba(0, 0, 0, .9);
}
.project-media:hover { box-shadow: 0 50px 90px -40px rgba(0, 0, 0, .9), 0 0 0 1px color-mix(in srgb, var(--acc) 40%, transparent), 0 0 40px -10px var(--acc); }
.window-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--border); background: #111821; }
.window-bar i { width: 9px; height: 9px; border-radius: 50%; background: #2a3442; }
.window-bar i:nth-child(1) { background: #ff6b4a; }
.window-bar i:nth-child(2) { background: var(--rl-blue); }
.window-bar i:nth-child(3) { background: var(--rl-cyan); }
.window-bar .mono { margin-left: 10px; color: var(--muted); font-size: 10px; text-transform: none; }
.project-media-img { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; }
.project-media-img img { width: 100%; height: 115%; object-fit: cover; }
.project-media-img .thumb-fallback { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); }

/* Glow che segue il cursore (impostato via JS con --mx/--my) */
.glow { position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .3s; background: radial-gradient(360px circle at var(--mx, 50%) var(--my, 50%), color-mix(in srgb, var(--acc, var(--rl-cyan)) 22%, transparent), transparent 60%); }
[data-tilt]:hover .glow { opacity: 1; }

/* --------------------------------------------------------------------------
   Altri esperimenti
   -------------------------------------------------------------------------- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.tilt-card {
	--acc: var(--rl-cyan);
	position: relative; display: flex; flex-direction: column; padding: 14px 14px 18px; border: 1px solid var(--border); border-radius: 4px;
	background: #0e141c; transform-style: preserve-3d; transition: border-color .3s, transform .2s;
}
.tilt-card:hover { border-color: color-mix(in srgb, var(--acc) 45%, transparent); }
.tilt-media { position: relative; display: block; aspect-ratio: 16 / 11; margin-bottom: 18px; overflow: hidden; border-radius: 3px; background: #111821; }
.tilt-media img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(.85) contrast(1.1); transition: filter .5s, transform .6s var(--ease); }
.tilt-card:hover .tilt-media img { filter: grayscale(0); transform: scale(1.05); }
.tilt-tag { position: absolute; top: 8px; right: 8px; padding: 3px 7px; border: 1px solid color-mix(in srgb, var(--acc) 50%, transparent); border-radius: 2px; background: rgba(10, 14, 20, .8); color: var(--acc); font-size: 9px; }
.tilt-title { font: 600 18px/1.25 var(--font-head); color: var(--heading); }
.tilt-text { margin-top: 8px; color: var(--text); font-size: 13.5px; line-height: 1.55; flex: 1; }
.tilt-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--border); color: var(--muted); font-size: 9.5px; }
.tilt-card:hover .tilt-foot { color: var(--acc); }

/* --------------------------------------------------------------------------
   Modelli 3D
   -------------------------------------------------------------------------- */
.models-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 24px; align-items: stretch; }
.models-layout .viewer { min-height: 520px; }
.model-list { display: flex; flex-direction: column; gap: 10px; list-style: none; margin: 0; padding: 0; }
.model-item {
	display: grid; grid-template-columns: 56px 1fr; gap: 14px; align-items: center; width: 100%; padding: 12px; text-align: left;
	border: 1px solid var(--border); border-radius: 4px; background: #0e141c; color: var(--text); transition: border-color .25s, background-color .25s;
}
.model-item:hover { border-color: rgba(92, 225, 230, .35); }
.model-item.is-active { border-color: var(--rl-cyan); background: rgba(92, 225, 230, .06); box-shadow: inset 3px 0 0 var(--rl-cyan); }
.model-thumb { position: relative; display: block; aspect-ratio: 1; overflow: hidden; border-radius: 3px; background: #111821; }
.model-thumb img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1); }
.model-thumb .thumb-fallback { background: transparent; }
.model-thumb .thumb-fallback .icon { width: 24px; height: 24px; }
.model-name { display: block; color: var(--heading); font-weight: 500; font-size: 15px; }
.model-specs { display: block; margin-top: 4px; color: var(--muted); font-size: 9.5px; text-transform: none; letter-spacing: .04em; }
.model-list-more { margin-top: 8px; }
.model-desc { margin: 6px 0 0; padding: 14px 16px; border-left: 2px solid var(--rl-cyan); background: rgba(92, 225, 230, .04); color: var(--text); font-size: 14.5px; line-height: 1.6; }
.model-desc:empty { display: none; }

/* --------------------------------------------------------------------------
   Pubblicazioni (ORCID) — stile worklist
   -------------------------------------------------------------------------- */
.pubs-box { position: relative; padding: 8px clamp(14px, 2.4vw, 28px) 18px; border: 1px solid var(--border); border-radius: 4px; background: #0b1017; }
.pubs-cols, .pub-row { display: grid; grid-template-columns: 70px 56px 110px minmax(0, 1fr) auto; align-items: center; gap: 16px; }
.pubs-cols { padding: 10px 0; border-bottom: 1px solid var(--border); color: var(--muted); font-size: 9.5px; }
.pub-list { list-style: none; margin: 0; padding: 0; }
.pub-row { padding: 16px 0; border-bottom: 1px dashed rgba(92, 225, 230, .1); transition: background-color .25s; }
.pub-row:last-child { border-bottom: 0; }
.pub-row:hover { background: linear-gradient(90deg, rgba(92, 225, 230, .05), transparent 70%); }
.pub-acc { color: rgba(92, 225, 230, .5); font-size: 10px; }
.pub-year { color: var(--heading); font-size: 13px; }
.pub-type { justify-self: start; padding: 3px 8px; border: 1px solid rgba(92, 225, 230, .3); border-radius: 2px; color: var(--rl-cyan); font-size: 9.5px; white-space: nowrap; }
.pub-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.pub-title { color: var(--heading); font: 600 clamp(15px, 1.4vw, 18px)/1.35 var(--font-head); letter-spacing: -.01em; }
a.pub-title:hover { color: var(--rl-cyan); }
.pub-venue { color: var(--muted); font-size: 13.5px; font-style: italic; }
.pub-doi { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border: 1px solid var(--border); border-radius: 3px; color: var(--heading); font-size: 10.5px; transition: border-color .2s, color .2s; }
.pub-doi:hover { border-color: var(--rl-cyan); color: var(--rl-cyan); }
.pubs-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border); color: var(--muted); }
.pubs-foot .mono { font-size: 10px; }

.pubs-subtitle { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 10px 0 0; color: var(--rl-cyan); font-size: 10.5px; }
.pubs-subtitle span { color: var(--muted); }

/* Incarichi associativi */
.roles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 16px; margin-bottom: 20px; }
.org-card { position: relative; padding: clamp(18px, 2.4vw, 26px); border: 1px solid var(--border); border-radius: 4px; background: linear-gradient(160deg, rgba(17, 24, 33, .95), rgba(11, 16, 23, .9)); }
.org-head { display: flex; align-items: center; gap: 16px; padding-bottom: 16px; border-bottom: 1px solid var(--border); }
.org-head > div { flex: 1; min-width: 0; }
/* piastrina bianca: il logo ha parti blu scuro che sul nero sparirebbero */
.org-logo { flex: none; display: grid; place-items: center; width: 64px; height: 64px; padding: 6px; border-radius: 12px; background: #fff; box-shadow: 0 8px 24px -10px rgba(0, 0, 0, .8); }
.org-logo img { width: 100%; height: 100%; object-fit: contain; }
.org-kicker { margin: 0 0 4px; color: var(--muted); font-size: 9.5px; }
.org-name { margin: 0; font-size: clamp(20px, 2vw, 26px); font-weight: 600; letter-spacing: -.02em; }
.org-link { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border: 1px solid var(--border); border-radius: 3px; color: var(--heading); font-size: 10px; }
.org-link:hover { border-color: var(--rl-cyan); color: var(--rl-cyan); }
.org-roles { list-style: none; margin: 0; padding: 0; }
.org-roles li { display: grid; grid-template-columns: 10px 1fr auto; align-items: baseline; gap: 12px; padding: 12px 0; border-bottom: 1px dashed rgba(92, 225, 230, .1); }
.org-roles li:last-child { border-bottom: 0; padding-bottom: 0; }
.role-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--rl-cyan); box-shadow: 0 0 8px var(--rl-cyan); transform: translateY(-2px); }
.role-name { color: var(--heading); font-weight: 500; font-size: 15.5px; line-height: 1.4; }
.role-period { color: var(--muted); font-size: 10px; white-space: nowrap; }

/* "In collaborazione con" (progetti) */
.partner { display: inline-flex; align-items: center; gap: 12px; margin-top: 18px; padding: 8px 14px 8px 8px; border: 1px solid var(--border); border-radius: 999px; background: rgba(255, 255, 255, .02); color: var(--heading); font-size: 14px; transition: border-color .25s; }
.partner img { width: 40px; height: 40px; padding: 4px; border-radius: 50%; background: #fff; object-fit: contain; }
.partner > span { display: flex; flex-direction: column; gap: 2px; line-height: 1.2; }
.partner .mono { color: var(--muted); font-size: 9px; }
a.partner:hover { border-color: var(--acc, var(--rl-cyan)); }

/* Riga credenziale nell'hero */
.hero-credential { display: inline-flex; align-items: center; gap: 10px; margin-top: 18px; padding: 6px 14px 6px 6px; border: 1px solid var(--border); border-radius: 999px; background: rgba(14, 20, 28, .7); color: var(--heading); font-size: 13.5px; transition: border-color .25s, color .25s; }
.hero-credential img { width: 28px; height: 28px; padding: 3px; border-radius: 50%; background: #fff; object-fit: contain; }
a.hero-credential:hover { border-color: var(--rl-cyan); color: var(--rl-cyan); }
.hero-credential + .hero-text { margin-top: 18px; }

/* Riquadro "Pubblicazioni correlate" (pagine progetto e modelli) */
.pubs-related { max-width: 980px; margin: 56px auto 0; padding: 16px clamp(14px, 2.4vw, 26px) 8px; border: 1px solid var(--border); border-radius: 4px; background: #0b1017; }
.pubs-related-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pubs-related-head .ws-label { display: flex; align-items: center; gap: 8px; margin: 0; }
.pubs-orcid { display: inline-flex; align-items: center; gap: 6px; color: #a6ce39; font-size: 10px; }
.pubs-orcid:hover { opacity: .8; }
.pubs-related .pub-row { grid-template-columns: 56px 110px minmax(0, 1fr) auto; }
.pubs-related .pub-acc { display: none; }

/* Collegamento compatto sotto un progetto o nella sezione modelli */
.project-pub {
	display: flex; align-items: center; gap: 12px; margin-top: 18px; padding: 12px 14px;
	border: 1px solid var(--border); border-left: 2px solid var(--acc, var(--rl-cyan)); border-radius: 3px;
	background: rgba(255, 255, 255, .015); color: var(--text); font-size: 14px; line-height: 1.4; transition: border-color .25s, background-color .25s;
}
.project-pub > span { flex: 1; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.project-pub .mono { color: var(--acc, var(--rl-cyan)); font-size: 9.5px; }
.project-pub .icon:first-child { flex: none; color: var(--acc, var(--rl-cyan)); }
.project-pub:hover { border-color: color-mix(in srgb, var(--acc, var(--rl-cyan)) 50%, transparent); background: rgba(92, 225, 230, .04); color: var(--heading); }
.model-list .project-pub { margin-top: 6px; }

@media (max-width: 760px) {
	.pubs-cols { display: none; }
	.pub-row, .pubs-related .pub-row { grid-template-columns: auto 1fr auto; grid-template-areas: "year type doi" "main main main"; gap: 8px 12px; }
	.pub-acc { display: none; }
	.pub-year { grid-area: year; }
	.pub-type { grid-area: type; }
	.pub-doi { grid-area: doi; }
	.pub-main { grid-area: main; }
	.org-head { flex-wrap: wrap; }
	.org-roles li { grid-template-columns: 10px 1fr; }
	.role-period { grid-column: 2; }
	.hero-credential { font-size: 12.5px; }
}

/* --------------------------------------------------------------------------
   Numeri
   -------------------------------------------------------------------------- */
.stats { border-block: 1px solid var(--border); background: rgba(17, 24, 33, .6); }
.stats-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 24px; padding-top: 40px; }
.stats-head .section-kicker { width: 100%; margin: 0; }
.stats-head .section-heading { font-size: clamp(26px, 3.2vw, 40px); }
.stats-head .section-aside { margin: 0; }
.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.stat { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 44px 16px; text-align: center; }
.stat + .stat { border-left: 1px solid var(--border); }
.stat-value { font: 600 clamp(40px, 5vw, 64px)/1 var(--font-head); letter-spacing: -.03em; color: var(--rl-cyan); text-shadow: 0 0 30px rgba(92, 225, 230, .35); font-variant-numeric: tabular-nums; }
.stat-value.is-blue { color: var(--rl-blue); text-shadow: 0 0 30px rgba(47, 123, 255, .35); }
.stat-label { color: var(--muted); font-size: 10px; }

/* --------------------------------------------------------------------------
   Dal blog
   -------------------------------------------------------------------------- */
.dispatch-list { display: flex; flex-direction: column; gap: 14px; }
.dispatch { display: grid; grid-template-columns: 180px 1fr auto; gap: 28px; align-items: center; padding: 16px; border: 1px solid var(--border); border-radius: 4px; background: #0e141c; transition: border-color .3s, transform .3s var(--ease); }
.dispatch:hover { border-color: rgba(92, 225, 230, .35); transform: translateX(6px); }
.dispatch-media { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; border-radius: 3px; background: #111821; }
.dispatch-media img { width: 100%; height: 100%; object-fit: cover; }
.dispatch-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 10px; color: var(--muted); font-size: 10px; }
.pill { padding: 3px 8px; border: 1px solid rgba(92, 225, 230, .35); border-radius: 2px; color: var(--rl-cyan); }
.dispatch-title { margin: 0 0 8px; font-size: clamp(18px, 1.8vw, 23px); font-weight: 600; letter-spacing: -.01em; }
.dispatch-title a:hover { color: var(--rl-cyan); }
.dispatch-excerpt { margin: 0; color: var(--text); font-size: 14px; }
.dispatch-go { display: flex; align-items: center; gap: 8px; padding-right: 10px; color: var(--muted); font-size: 10px; }
.dispatch:hover .dispatch-go { color: var(--rl-cyan); }

/* --------------------------------------------------------------------------
   Podcast
   -------------------------------------------------------------------------- */
.podcast { padding-top: 0; }
.podcast-box { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; padding: clamp(28px, 4vw, 56px); border: 1px solid var(--border); border-radius: 4px; background: radial-gradient(80% 120% at 100% 0%, rgba(47, 123, 255, .14), transparent 60%), #0e141c; }
.podcast-copy .section-heading { font-size: clamp(28px, 3.4vw, 40px); margin: 10px 0 14px; }
.podcast-copy p { max-width: 440px; }
.podcast-player { position: relative; min-height: 152px; display: grid; align-items: center; }
.podcast-player iframe { width: 100%; height: 232px; border: 0; border-radius: 12px; }
.podcast-load { display: flex; align-items: center; gap: 18px; width: 100%; padding: 22px; border: 1px solid var(--border); border-radius: 12px; background: rgba(10, 14, 20, .6); text-align: left; transition: border-color .3s; }
.podcast-load:hover { border-color: var(--rl-cyan); }
.podcast-load small { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; }
.podcast-load .mono { color: var(--heading); }
.podcast-play { display: grid; place-items: center; flex: none; width: 60px; height: 60px; border-radius: 50%; background: linear-gradient(135deg, var(--rl-cyan), var(--rl-blue)); color: #04161a; box-shadow: 0 0 30px -4px var(--rl-cyan); }
.eq { position: absolute; left: 22px; right: 22px; bottom: -34px; display: flex; align-items: flex-end; gap: 4px; height: 26px; }
.eq i { flex: 1; background: rgba(92, 225, 230, .35); border-radius: 1px; animation: rl-eq 1.2s ease-in-out infinite; }
.eq i:nth-child(3n) { animation-delay: -.4s; }
.eq i:nth-child(3n+1) { animation-delay: -.8s; }
.eq i:nth-child(4n) { animation-duration: .9s; }
@keyframes rl-eq { 0%, 100% { height: 20%; } 50% { height: 100%; } }
.podcast-player.is-loaded .eq { display: none; }

/* --------------------------------------------------------------------------
   Stato iniziale animazioni (solo con JS attivo e motion consentito)
   -------------------------------------------------------------------------- */
.motion [data-hero-in] { opacity: 0; transform: translateY(24px); }
.motion [data-reveal] { opacity: 0; }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1100px) {
	.models-layout { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
	.hero-inner { grid-template-columns: 1fr; }
	/* Mobile: visual sotto il testo, a tutta larghezza; tesserino più grande e cordino corto per non coprire i pulsanti */
	.hero-visual { justify-self: center; width: 100%; max-width: 560px; margin: 56px 0 0; aspect-ratio: 1.05; }
	.lightbox { width: 86%; top: 4%; }
	.badge-wrap { width: 42%; top: 30%; right: -2%; }
	.lanyard { height: 104px; mask-image: linear-gradient(transparent, #000 25%); }
	.lanyard-text { font-size: 9px; padding-top: 12px; }
	.scroll-hint { display: none; }
	.project-feature, .project-feature.is-reversed { grid-template-columns: 1fr; }
	.project-feature.is-reversed .project-copy { order: 0; }
	.podcast-box { grid-template-columns: 1fr; }
	.stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.stat:nth-child(3) { border-left: 0; }
	.stat:nth-child(n+3) { border-top: 1px solid var(--border); }
	.dispatch { grid-template-columns: 120px 1fr; }
	.dispatch-go { display: none; }
	.slice-indicator { display: none; }
}
@media (max-width: 560px) {
	.section-head { grid-template-columns: 1fr; }
	.dispatch { grid-template-columns: 1fr; gap: 14px; }
	.hero-visual { aspect-ratio: .95; }
	.lightbox { width: 92%; }
	.badge-wrap { width: 48%; top: 34%; right: -3%; }
	.badge-foot { display: none; }
	.hero { padding-bottom: 72px; }
	.scroll-hint { display: none; }
	.models-layout .viewer { min-height: 420px; }
}
