/*
 * Home PubMe — ricerca e sviluppo editoriale.
 * Componenti comuni del nuovo stile in v2.css; header, footer, contatti e cookie in home.css.
 */

/* ---------- Apertura ---------- */

.hx {
    position: relative;
    isolation: isolate;
    min-height: max(780px, 100svh);
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    grid-template-rows: 1fr auto;
    align-items: center;
    column-gap: clamp(16px, 3vw, 56px);
    padding: 150px var(--gutter) 0;
    overflow: hidden;
}
.hx::before {
    content: "";
    position: absolute;
    z-index: -1;
    inset: 0;
    opacity: .55;
    background-image: radial-gradient(rgba(17, 17, 15, .14) 1.2px, transparent 1.4px);
    background-size: 18px 18px;
    -webkit-mask-image: radial-gradient(70% 70% at 78% 46%, #000, transparent);
    mask-image: radial-gradient(70% 70% at 78% 46%, #000, transparent);
}

.hx__copy { position: relative; z-index: 2; padding: 24px 0 56px; }

.hx__kicker {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 clamp(22px, 2.6vw, 36px);
    font-family: "DM Mono", monospace;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: .16em;
    text-transform: uppercase;
}
.hx__kicker i { width: 12px; height: 12px; border: 2px solid var(--ink); border-radius: 50%; background: var(--orange); animation: kicker-pulse 2.4s ease-in-out infinite; }

.hx__title {
    margin: 0;
    font-size: clamp(44px, 6.4vw, 124px);
    font-weight: 800;
    letter-spacing: -.045em;
    line-height: .98;
    text-transform: uppercase;
}
.hx__line { display: block; }
.hx__line > span { display: inline-block; }

.hx__lead {
    margin: clamp(26px, 3vw, 40px) 0 0;
    max-width: 52ch;
    color: #3d3b35;
    font-size: clamp(16px, 1.3vw, 19px);
    line-height: 1.6;
}
.hx__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: clamp(26px, 3vw, 38px); }

.hx__facts {
    position: relative;
    z-index: 2;
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    width: calc(100% + var(--gutter) * 2);
    margin: 0 calc(var(--gutter) * -1);
    padding: 0 var(--gutter);
    background: var(--cream);
    border-top: 2px solid var(--ink);
}
.hx__facts > div { display: flex; flex-direction: column-reverse; gap: 6px; padding: 22px 0 26px; }
.hx__facts > div + div { padding-left: clamp(16px, 2vw, 32px); border-left: 1px solid var(--line); }
.hx__facts dd { margin: 0; font-size: clamp(30px, 3.4vw, 56px); font-weight: 800; letter-spacing: -.05em; line-height: 1; }
.hx__facts dt { color: var(--muted); font-family: "DM Mono", monospace; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; }

/* Entrata in CSS puro: parte subito, senza aspettare JavaScript né immagini. */
.hx__kicker { animation: hx-fade .8s var(--smooth) .05s both; }
.hx__line { animation: hx-rise .95s var(--smooth) both; }
.hx__line:nth-child(1) { animation-delay: .12s; }
.hx__line:nth-child(2) { animation-delay: .24s; }
.hx__line:nth-child(3) { animation-delay: .36s; }
.hx__lead,
.hx__actions { animation: hx-fade 1s var(--smooth) .7s both; }

@keyframes hx-rise { from { opacity: 0; transform: translateY(.45em); } }
@keyframes kicker-pulse { 50% { transform: scale(.7); } }

/* ---------- Libro pop-up a fumetti (la scena a strati è in v2.css) ---------- */


/* La pagina che si sfoglia avanti e indietro, imperniata sulla costola del libro. */
.scene__flip {
    position: absolute;
    left: 50%;
    top: 47.66%;
    width: 38%;
    height: 34.66%;
    transform-origin: 0 50%;
    transform-style: preserve-3d;
    animation: sc-flip 7.5s cubic-bezier(.6, 0, .25, 1) infinite;
}
.scene__face { position: absolute; inset: 0; backface-visibility: hidden; }
.scene__face svg { display: block; width: 100%; height: 100%; overflow: visible; }
.scene__face--back { transform: rotateY(180deg); }
.scene__face--back svg { transform: scaleX(-1); }

.sc-spin { transform-box: view-box; transform-origin: 300px 262px; animation: sc-spin 40s linear infinite; }
.sc-gear { transform-box: fill-box; transform-origin: center; animation: sc-spin 9s linear infinite reverse; }
.sc-cursor { animation: blink 1.1s steps(1) infinite; }
.sc-bubble { transform-box: fill-box; transform-origin: center; animation: sc-bubble 2.4s ease-in infinite; }
.sc-bubble--2 { animation-delay: -.8s; }
.sc-bubble--3 { animation-delay: -1.6s; }

@keyframes sc-bubble { 0% { transform: translateY(0) scale(.6); opacity: 0; } 20% { opacity: 1; } 100% { transform: translateY(-110px) scale(1.1); opacity: 0; } }
@keyframes sc-flip {
    0%, 18% { transform: rotateY(0); }
    46%, 64% { transform: rotateY(-178deg); }
    92%, 100% { transform: rotateY(0); }
}

/* ---------- Cosa facciamo: parole che si scompongono ---------- */

.jobs { padding: clamp(100px, 11vw, 170px) var(--gutter) clamp(90px, 10vw, 150px); overflow-x: clip; }
.jobs__head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 40px;
    width: min(100%, var(--wrap));
    margin: 0 auto 28px;
}
.jobs__head p { max-width: 44ch; margin: 0; color: #3d3b35; font-size: 16px; line-height: 1.55; }
.jobs__hint { color: var(--ink); font-weight: 800; }
.jobs__hint--touch { display: none; }
@media (hover: none) {
    .jobs__hint--pointer { display: none; }
    .jobs__hint--touch { display: inline; }
}

.jobs__list { width: min(100%, var(--wrap)); margin: 0 auto; border-top: 2px solid var(--ink); }

.job {
    --tone: var(--yellow);
    --tone-fg: var(--ink);
    position: relative;
    isolation: isolate;
    border-bottom: 2px solid var(--ink);
    /* Taglia le lettere sparse in alto e in basso, ma lascia il colore uscire ai lati fino ai bordi dello schermo. */
    clip-path: inset(0 -100vmax);
    transition: color .4s;
}
.job--paper { --tone: var(--paper); }
.job--orange { --tone: var(--orange); }
.job--ink { --tone: var(--night); --tone-fg: var(--paper); }
.job::before {
    content: "";
    position: absolute;
    z-index: -2;
    inset: 0 -100vmax;
    background: var(--dots), var(--tone);
    transform: scaleY(0);
    transform-origin: top;
    transition: transform .55s cubic-bezier(.7, 0, .2, 1);
}
.job--ink::before { background: radial-gradient(rgba(245, 238, 219, .1) 1.4px, transparent 1.6px) 0 0 / 12px 12px, var(--tone); }
.job.is-open { color: var(--tone-fg); }
.job.is-open::before { transform: scaleY(1); }

.job__toggle {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
    padding: clamp(10px, 1.3vw, 20px) 4px;
    color: inherit;
    background: none;
    border: 0;
    font: inherit;
    text-align: left;
    cursor: pointer;
}
.job__word {
    position: relative;
    z-index: -1;
    font-size: clamp(48px, 9vw, 168px);
    font-weight: 800;
    letter-spacing: -.065em;
    line-height: .92;
    white-space: nowrap;
}
/* Ogni lettera ha la sua traiettoria (--dx, --dy, --r): all'apertura la parola esplode e resta in trasparenza. */
.job__char {
    display: inline-block;
    transition: transform .8s var(--pop), opacity .55s;
    transition-delay: calc(var(--i) * 22ms);
}
.job:not(.is-open) .job__toggle:hover .job__char { transform: translateY(-.05em) rotate(calc(var(--r) * .12)); transition-duration: .3s; }
.job.is-open .job__char { opacity: .15; transform: translate(var(--dx), var(--dy)) rotate(var(--r)) scale(.94); }

.job__plus {
    position: relative;
    flex: none;
    width: 46px;
    height: 46px;
    border: 2.5px solid currentColor;
    border-radius: 50%;
    transition: transform .45s var(--pop), background-color .3s;
}
.job__plus::before,
.job__plus::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 17px;
    height: 2.5px;
    background: currentColor;
    border-radius: 2px;
    transform: translate(-50%, -50%);
}
.job__plus::after { transform: translate(-50%, -50%) rotate(90deg); }
.job.is-open .job__plus { transform: rotate(135deg); }

/* La riga si apre: altezza animata con la griglia 0fr → 1fr. */
.job__body {
    display: grid;
    grid-template-rows: 0fr;
    visibility: hidden;
    transition: grid-template-rows .6s var(--smooth), visibility 0s .6s;
}
.job.is-open .job__body { grid-template-rows: 1fr; visibility: visible; transition: grid-template-rows .6s var(--smooth), visibility 0s; }
.job__inner { min-height: 0; overflow: hidden; }
.job__grid {
    display: grid;
    grid-template-columns: minmax(260px, 430px) minmax(0, 1fr) auto;
    align-items: center;
    gap: clamp(24px, 4vw, 70px);
    padding: 0 4px clamp(30px, 3vw, 48px);
}

.job__art { position: relative; display: grid; place-items: center; height: clamp(230px, 19vw, 290px); }
.job__info { display: grid; align-content: center; gap: 14px; }
.job__info .label { color: inherit; opacity: .75; }
.job__info h3 { margin: 0; font-size: clamp(32px, 3.2vw, 54px); font-weight: 800; letter-spacing: -.05em; line-height: .98; }
.job__text { max-width: 46ch; margin: 0; font-size: 17px; line-height: 1.55; }
.job__info ul { display: grid; gap: 10px; margin: 2px 0 0; padding: 0; list-style: none; }
.job__info li { position: relative; padding-left: 32px; font-size: 15px; font-weight: 600; line-height: 1.45; }
.job__info li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 1px;
    width: 20px;
    height: 20px;
    background: var(--yellow);
    border: 2px solid var(--ink);
    border-radius: 6px;
}
.job__info li::after {
    content: "";
    position: absolute;
    left: 7px;
    top: 5px;
    width: 6px;
    height: 10px;
    border: solid var(--ink);
    border-width: 0 2.5px 2.5px 0;
    transform: rotate(45deg);
}
.job--yellow .job__info li::before { background: var(--paper); }
.job--ink .btn--ink { color: var(--ink); background: var(--yellow); border-color: var(--yellow); }
.job--ink .btn--ink:hover { box-shadow: 4px 5px 0 var(--paper); }

/* Prima esplodono le lettere, poi arrivano libri, informazioni e pulsante. */
.job.is-open .job__art { animation: job-art .75s var(--pop) .15s both; }
.job.is-open .job__info { animation: hx-fade .6s var(--smooth) .28s both; }
.job.is-open .job__info li { animation: hx-fade .5s var(--smooth) both; }
.job.is-open .job__info li:nth-child(1) { animation-delay: .42s; }
.job.is-open .job__info li:nth-child(2) { animation-delay: .5s; }
.job.is-open .job__info li:nth-child(3) { animation-delay: .58s; }
.job.is-open .job__go { animation: job-go .6s var(--pop) .5s both; }
@keyframes job-art { from { opacity: 0; transform: scale(.75) rotate(-5deg); } }
@keyframes job-go { from { opacity: 0; transform: scale(.5) rotate(6deg); } }

.job__art > .dbook { left: 50%; top: 50%; }
.job__art > .dbook:nth-child(1) { --fan: translate(-118%, -48%) rotate(-14deg); }
.job__art > .dbook:nth-child(2) { --fan: translate(18%, -46%) rotate(12deg); }
.job__art > .dbook:nth-child(3) { --fan: translate(-50%, -54%) rotate(-2deg); }
.job__art > .dbook { transform: var(--fan); }
.job.is-open .job__art > .dbook { animation: fan-open .8s var(--pop) both, float 4.5s ease-in-out 1s infinite; }
.job.is-open .job__art > .dbook:nth-child(1) { animation-delay: .12s, 1s; }
.job.is-open .job__art > .dbook:nth-child(2) { animation-delay: .2s, 1.6s; }
@keyframes fan-open { from { transform: translate(-50%, -30%) rotate(0) scale(.8); opacity: 0; } }
@keyframes float { 50% { transform: var(--fan) translateY(-8px); } }

/* Curiamo: barrature e correzioni che si scrivono da sole */
.proof {
    position: relative;
    width: min(84%, 380px);
    padding: 22px 24px 40px;
    background: var(--paper);
    border: 2.5px solid var(--ink);
    border-radius: 10px;
    box-shadow: 9px 10px 0 var(--ink);
    transform: rotate(-2deg);
}
.proof p { margin: 0; font-family: var(--serif); font-size: clamp(16px, 1.35vw, 19px); line-height: 1.6; }
.proof del {
    color: #8a8478;
    text-decoration: none;
    background: linear-gradient(var(--orange), var(--orange)) 0 56% / 0 2.5px no-repeat;
}
.proof__ins {
    background: linear-gradient(rgba(245, 183, 27, .75), rgba(245, 183, 27, .75)) 0 100% / 0 100% no-repeat;
}
.job.is-open .proof del { animation: strike .45s ease-out both; }
.job.is-open .proof del:nth-of-type(1) { animation-delay: .5s; }
.job.is-open .proof del:nth-of-type(2) { animation-delay: 1.2s; }
.job.is-open .proof__ins { animation: highlight .55s ease-out both; }
.job.is-open .proof__ins:nth-of-type(1) { animation-delay: .85s; }
.job.is-open .proof__ins:nth-of-type(2) { animation-delay: 1.55s; }
.proof__note {
    position: absolute;
    right: 14px;
    bottom: 12px;
    color: var(--orange);
    font-family: "DM Mono", monospace;
    font-size: 10px;
    letter-spacing: .1em;
    text-transform: uppercase;
}
@keyframes strike { to { background-size: 100% 2.5px; } }
@keyframes highlight { to { background-size: 100% 100%; } }

/* Stampiamo: il libro gira e le copie si impilano */
.job__art .book3d { position: relative; z-index: 1; width: 128px; height: 190px; transform-style: preserve-3d; animation: book-turn 5s ease-in-out infinite alternate; }
.job--orange .job__art { perspective: 900px; }
.book3d__front.dbook { inset: 0; width: 100%; height: 100%; box-shadow: none; transform: translateZ(15px); }
.book3d__spine,
.book3d__pages { position: absolute; top: 0; width: 30px; height: 100%; }
.book3d__spine { left: 0; background: linear-gradient(90deg, #11110f, #3a3833 45%, #11110f); transform: rotateY(-90deg) translateZ(15px); }
.book3d__pages { right: 0; background: repeating-linear-gradient(90deg, #f7f2e4 0 2px, #e4dcc6 2px 3px); transform: rotateY(90deg) translateZ(15px); }
@keyframes book-turn { from { transform: rotateX(8deg) rotateY(10deg); } to { transform: rotateX(4deg) rotateY(40deg); } }

.stack {
    position: absolute;
    left: 50%;
    width: 120px;
    height: 20px;
    margin-left: -230px;
    background: var(--paper);
    border: 2.5px solid var(--ink);
    border-radius: 4px;
    box-shadow: 5px 5px 0 var(--ink);
}
.stack--1 { bottom: 34px; }
.stack--2 { bottom: 56px; background: var(--yellow); }
.stack--3 { bottom: 78px; }
.job.is-open .stack { animation: drop .55s var(--pop) both; }
.job.is-open .stack--1 { animation-delay: .25s; }
.job.is-open .stack--2 { animation-delay: .45s; }
.job.is-open .stack--3 { animation-delay: .65s; }
@keyframes drop { from { opacity: 0; transform: translateY(-60px) rotate(-6deg); } }

/* Sviluppiamo: finestre di codice che si scrivono */
.code-window {
    position: relative;
    z-index: 1;
    display: grid;
    align-content: start;
    gap: 12px;
    width: min(78%, 340px);
    padding: 40px 22px 26px;
    background: #1d1c19;
    border: 2.5px solid var(--paper);
    border-radius: 14px;
    box-shadow: 9px 10px 0 var(--orange);
}
.code-window > i { position: absolute; top: 14px; width: 9px; height: 9px; border-radius: 50%; background: #4a4741; }
.code-window > i:nth-child(1) { left: 16px; }
.code-window > i:nth-child(2) { left: 30px; }
.code-window > i:nth-child(3) { left: 44px; }
.code-window--back {
    position: absolute;
    z-index: 0;
    width: min(60%, 260px);
    height: 140px;
    padding: 0;
    transform: translate(26%, -36%) rotate(5deg);
    box-shadow: 9px 10px 0 var(--yellow);
    opacity: .85;
}
.code-line {
    position: relative;
    display: block;
    width: 0;
    height: 9px;
    background: var(--c, var(--paper));
    border-radius: 9px;
}
.job.is-open .code-line { animation: type-line .7s steps(12) var(--d, 0s) both; }
@keyframes type-line { from { width: 0; } to { width: var(--w); } }
.job.is-open .code-line { width: var(--w); }
.code-line--cursor::after {
    content: "";
    position: absolute;
    right: -16px;
    top: -4px;
    width: 9px;
    height: 17px;
    background: var(--yellow);
    animation: blink 1s steps(1) infinite;
}
.gear {
    position: absolute;
    z-index: 2;
    right: 9%;
    bottom: 12%;
    width: 58px;
    height: 58px;
    background: radial-gradient(circle, var(--paper) 0 7px, var(--ink) 7.5px 10px, var(--yellow) 10.5px 19px, var(--ink) 19.5px 22px, transparent 22.5px);
    border-radius: 50%;
    animation: sc-spin 8s linear infinite;
}
.gear::before {
    content: "";
    position: absolute;
    inset: -2px;
    z-index: -1;
    border-radius: 50%;
    background: repeating-conic-gradient(var(--ink) 0 18deg, transparent 18deg 45deg);
    -webkit-mask: radial-gradient(circle, transparent 20px, #000 20.5px 31px, transparent 31.5px);
    mask: radial-gradient(circle, transparent 20px, #000 20.5px 31px, transparent 31.5px);
}

/* ---------- Software: il catalogo ---------- */

.lab {
    position: relative;
    padding: clamp(100px, 11vw, 170px) var(--gutter) clamp(90px, 10vw, 150px);
    color: var(--cream);
    background:
        linear-gradient(rgba(245, 238, 219, .055) 1px, transparent 1px) 0 0 / 40px 40px,
        linear-gradient(90deg, rgba(245, 238, 219, .055) 1px, transparent 1px) 0 0 / 40px 40px,
        var(--night);
}
.lab__head {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    align-items: end;
    gap: 22px clamp(32px, 5vw, 90px);
    width: min(100%, var(--wrap));
    margin: 0 auto clamp(48px, 6vw, 80px);
}
.lab__head .label { grid-column: 1 / -1; }
.lab__head h2 { margin: 0; font-size: clamp(48px, 7vw, 128px); font-weight: 800; letter-spacing: -.06em; line-height: .9; }
.lab__head > p:last-child { max-width: 46ch; margin: 0; color: #bdb6a6; font-size: 17px; line-height: 1.6; }

/* Il registro di laboratorio: una riga per prodotto, separate da un filo. Niente riquadri:
   al passaggio sotto il nome si disegna la sottolineatura ondulata del menu e salta fuori l'icona a fumetto. */
.register {
    width: min(100%, var(--wrap));
    margin: 0 auto;
    padding: 0;
    list-style: none;
    border-top: 1.5px solid rgba(245, 238, 219, .3);
}
.register__row { border-bottom: 1.5px solid rgba(245, 238, 219, .3); }
.register__link {
    --accent: var(--yellow);
    position: relative;
    isolation: isolate;
    display: grid;
    grid-template-columns: 74px minmax(0, 1.15fr) minmax(150px, 230px) minmax(0, 1fr) 44px;
    align-items: center;
    gap: clamp(16px, 2.4vw, 40px);
    padding: clamp(20px, 2.2vw, 32px) 0;
    color: var(--cream);
    text-decoration: none;
    transition: color .3s .05s;
}
.register__link--orange { --accent: var(--orange); }
.register__link--paper { --accent: var(--cream); }

.register__code { color: var(--yellow); font-family: "DM Mono", monospace; font-size: 13px; font-weight: 500; letter-spacing: .08em; transition: color .3s; }

.register__name {
    display: flex;
    align-items: center;
    font-size: clamp(30px, 3.6vw, 62px);
    font-weight: 800;
    letter-spacing: -.055em;
    line-height: 1;
}
/* L'icona non occupa spazio finché non passi sopra: poi cresce, scatta in posizione e spinge il nome. */
.register__icon {
    display: inline-grid;
    place-items: center;
    flex: none;
    width: 0;
    height: 1.1em;
    margin-right: 0;
    overflow: visible;
    opacity: 0;
    transform: scale(.2) rotate(-25deg);
    transition: width .45s cubic-bezier(.34, 1.56, .64, 1), margin .45s cubic-bezier(.34, 1.56, .64, 1), opacity .25s, transform .5s cubic-bezier(.34, 1.56, .64, 1);
}
.register__icon .comic-icon { width: 1.05em; height: 1.05em; }
.register__icon .comic-icon { stroke: var(--cream); }
.register__name { position: relative; }
.register__name::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -.2em;
    height: .16em;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 10' preserveAspectRatio='none'%3E%3Cpath d='M2 6Q8 1 14 6T26 6T38 6T50 6T62 6' fill='none' stroke='%23ef6d20' stroke-width='2.6' stroke-linecap='round'/%3E%3C/svg%3E") left center / 0% 100% no-repeat;
    transition: background-size .55s cubic-bezier(.65, 0, .35, 1);
}
a.register__link:hover .register__name::after,
a.register__link:focus-visible .register__name::after { background-size: 100% 100%; }
a.register__link:hover .register__code { color: var(--orange); }
a.register__link:hover .register__icon,
a.register__link:focus-visible .register__icon { width: 1.1em; margin-right: .22em; opacity: 1; transform: none; }

.register__meta { display: flex; flex-wrap: wrap; gap: 8px 14px; font-family: "DM Mono", monospace; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
.register__status { display: inline-flex; align-items: center; gap: 7px; }
.register__status::before {
    content: "";
    width: 9px;
    height: 9px;
    border: 1.5px solid currentColor;
    border-radius: 50%;
}
.register__status--new::before { background: var(--orange); border-color: var(--orange); animation: status-pulse 1.8s ease-out infinite; }
.register__status--live::before { background: var(--yellow); border-color: var(--yellow); }
@keyframes status-pulse { 0% { box-shadow: 0 0 0 0 rgba(239, 109, 32, .6); } 70%, 100% { box-shadow: 0 0 0 8px rgba(239, 109, 32, 0); } }

.register__text { color: #bdb6a6; font-size: 15px; line-height: 1.55; transition: color .3s; }
.register__arrow { justify-self: end; font-size: 30px; transition: transform .4s cubic-bezier(.34, 1.56, .64, 1); }
a.register__link:hover .register__arrow { transform: translate(5px, -5px) rotate(8deg); }
.register__row--next .register__link { color: rgba(245, 238, 219, .7); }
.register__row--next .register__name { font-style: normal; -webkit-text-stroke: 0; }
.register__row--next .register__code { color: var(--orange); }

.comic-icon { overflow: visible; }

/* Su touch non c'è il passaggio del mouse: l'icona resta sempre visibile. */
@media (hover: none) {
    .register__icon { width: 1.1em; margin-right: .22em; opacity: 1; transform: none; }
}

/* ---------- Instagram ---------- */

.ig { padding: clamp(100px, 11vw, 180px) var(--gutter) clamp(70px, 8vw, 120px); }
.ig__head {
    display: flex;
    flex-wrap: wrap;
    align-items: end;
    justify-content: space-between;
    gap: 28px 48px;
    width: min(100%, var(--wrap));
    margin: 0 auto clamp(32px, 4vw, 56px);
}
.ig__head h2 { margin: 0; font-size: clamp(54px, 10vw, 190px); font-weight: 800; letter-spacing: -.07em; line-height: .84; }
.ig__head h2 a {
    color: inherit;
    text-decoration: none;
    background: linear-gradient(var(--orange), var(--orange)) 0 96% / 0 .07em no-repeat;
    transition: background-size .6s var(--smooth);
}
.ig__head h2 a:hover { background-size: 100% .07em; }
.ig__head > div { display: grid; justify-items: start; gap: 20px; max-width: 400px; }
.ig__head p { margin: 0; color: #3d3b35; font-size: 16px; line-height: 1.55; }

.ig__sample {
    width: min(100%, var(--wrap));
    margin: 0 auto 14px;
    color: var(--orange);
    font-family: "DM Mono", monospace;
    font-size: 10px;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.ig__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(8px, 1vw, 16px);
    width: min(100%, var(--wrap));
    margin: 0 auto;
    padding: 0;
    list-style: none;
}
.ig__grid li:first-child { grid-column: span 2; grid-row: span 2; }
.ig__grid a {
    position: relative;
    display: block;
    height: 100%;
    aspect-ratio: 1;
    overflow: hidden;
    background: var(--paper);
    border: 2px solid var(--ink);
    border-radius: 12px;
}
.ig__grid img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--smooth); }
.ig__grid a:hover img { transform: scale(1.06); }
.ig__type { position: absolute; top: 12px; right: 12px; width: 22px; height: 22px; filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .55)); }
.ig__type--fill { fill: #fff; }
.ig__type--stroke { fill: none; stroke: #fff; stroke-width: 2; stroke-linejoin: round; }
.ig__caption {
    position: absolute;
    inset: auto 0 0;
    padding: 46px 16px 16px;
    color: #fff;
    background: linear-gradient(transparent, rgba(17, 17, 15, .86));
    font-size: 13px;
    line-height: 1.45;
    transform: translateY(101%);
    transition: transform .5s var(--smooth);
}
.ig__grid a:hover .ig__caption,
.ig__grid a:focus-visible .ig__caption { transform: none; }

/* ---------- Partner ---------- */

.partners {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 24px 56px;
    width: min(100% - var(--gutter) * 2, var(--wrap));
    margin: 0 auto;
    padding: 40px 0 clamp(80px, 9vw, 130px);
    border-top: 2px solid var(--ink);
}
.partners ul { display: flex; flex-wrap: wrap; align-items: center; gap: 22px 48px; margin: 0; padding: 0; list-style: none; }
.partners img { display: block; width: auto; height: 46px; mix-blend-mode: multiply; filter: grayscale(1) contrast(1.15); opacity: .7; transition: filter .4s, opacity .4s; }
.partners li:hover img { filter: none; opacity: 1; }

/* ---------- Chiusura ---------- */

.start { padding: clamp(90px, 10vw, 160px) var(--gutter); background: var(--orange); }
.start h2 {
    width: min(100%, var(--wrap));
    margin: 0 auto clamp(36px, 4vw, 56px);
    font-size: clamp(54px, 9vw, 164px);
    font-weight: 800;
    letter-spacing: -.065em;
    line-height: .88;
}
.start__options {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    width: min(100%, var(--wrap));
    margin: 0 auto;
}
.start__options a {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 40px;
    min-height: 200px;
    padding: 22px 72px 22px 24px;
    color: var(--ink);
    background: var(--paper);
    border: 2px solid var(--ink);
    border-radius: 18px;
    box-shadow: 7px 8px 0 var(--ink);
    font-size: clamp(24px, 2.3vw, 36px);
    font-weight: 800;
    letter-spacing: -.035em;
    line-height: 1.04;
    text-decoration: none;
    transition: transform .4s var(--pop), box-shadow .4s var(--pop), background-color .3s;
}
.start__options small { font-family: "DM Mono", monospace; font-size: 11px; font-weight: 500; letter-spacing: .1em; }
.start__options span { position: absolute; right: 22px; bottom: 18px; font-size: 32px; transition: transform .4s var(--pop); }
.start__options a:hover { background: var(--yellow); transform: translate(-4px, -5px); box-shadow: 12px 13px 0 var(--ink); }
.start__options a:hover span { transform: translateX(5px); }
.start__options a:focus-visible { outline-color: var(--ink); }

/* ---------- Schermi medi e piccoli ---------- */

@media (max-width: 1100px) {
    .job__grid { grid-template-columns: minmax(220px, 340px) minmax(0, 1fr); }
    .job__go { grid-column: 2; }
}

@media (max-width: 900px) {
    .hx { grid-template-columns: 1fr; padding-top: 140px; min-height: 0; }
    .hx__copy { padding: 20px 0 8px; }
    .hx__title { font-size: 12vw; }
    .scene { width: min(100%, 520px); margin: 0 auto 24px; }
    .hx__facts { grid-template-columns: repeat(2, 1fr); }
    .hx__facts > div:nth-child(3) { padding-left: 0; border-left: 0; }
    .hx__facts > div:nth-child(n + 3) { border-top: 1px solid var(--line); }

    .jobs__head { flex-direction: column; align-items: start; gap: 14px; }
    .job__word { font-size: 11.5vw; }
    .job__plus { width: 38px; height: 38px; }
    .job__grid { grid-template-columns: 1fr; gap: 22px; }
    .job__go { grid-column: auto; }
    .job__art { height: 220px; }
    .stack { margin-left: -190px; }

    .lab__head { grid-template-columns: 1fr; }
    .register__link { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: 'code meta' 'name arrow' 'text text'; gap: 10px 16px; }
    .register__code { grid-area: code; }
    .register__meta { grid-area: meta; justify-content: end; }
    .register__name { grid-area: name; font-size: clamp(30px, 9vw, 46px); }
    .register__text { grid-area: text; }
    .register__arrow { grid-area: arrow; }
    .ig__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .start__options { grid-template-columns: 1fr; }
    .start__options a { min-height: 128px; }
}

@media (max-width: 560px) {
    .hx__actions .btn { flex: 1 1 auto; justify-content: center; }
    .job__go .btn { width: 100%; justify-content: center; }
    .stack { display: none; }
    .partners img { height: 36px; }
}

/* ---------- Chi preferisce meno movimento ---------- */

@media (prefers-reduced-motion: reduce) {
    .hx__kicker, .hx__kicker i, .hx__line, .hx__lead, .hx__actions, .scene,
    .scene__flip, .sc-spin, .sc-gear, .sc-bob, .sc-cursor, .sc-bubble, .sc-twinkle, .sc-pop,
    .job.is-open .job__art, .job.is-open .job__info, .job.is-open .job__go, .job.is-open .job__info li, .job.is-open .job__art > .dbook, .book3d, .gear,
    .job.is-open .stack, .code-line--cursor::after { animation: none; }
    .mark--circle path { animation: none; stroke-dashoffset: 0; }
    .mark--highlight::before { animation: none; transform: skewX(-8deg) scaleX(1); }
    .job.is-open .proof del { animation: none; background-size: 100% 2.5px; }
    .job.is-open .proof__ins { animation: none; background-size: 100% 100%; }
    .job.is-open .code-line { animation: none; }
    .sc-bubble { opacity: 0; }
    .job::before, .job__char, .job__body, .job__plus, .btn, .register__link, .register__name::after, .register__icon, .start__options a, .ig__grid img { transition: none; }
    .register__status--new::before { animation: none; }
    .job.is-open .job__char { transform: none; }
}
