:root {
    --bg-main: #050509;
    --bg-elevated: #101018;
    --bg-elevated-soft: #151524;
    --accent: #de0d29; /* Rosso principale NivaZ */
    --accent-soft: rgba(255, 48, 64, 0.18);
    --accent-strong: #ff2437;
    --text-main: #f5f5f7;
    --text-muted: #a0a0b5;
    --border-subtle: rgba(255, 255, 255, 0.08);
    --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.65);
    --radius-lg: 16px;
    --radius-pill: 999px;
    --transition-fast: 0.18s ease-out;
    --transition-med: 0.35s cubic-bezier(0.19, 1, 0.22, 1);
    --hero-bg-offset: 0px;
    --page-bg-offset: 0px;
}

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

html, body {
    margin: 0;
    padding: 0;
    background: #050509;
    /*background: radial-gradient(circle at top, #101020 0, #050509 55%, #020205 100%);*/
    color: var(--text-main);
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}
.page-bg-image {
    position: fixed;
    top: 5vh; /* sale sopra il viewport di 20% */
    left: 0;
    right: 0;
    height: 150vh; /* 100vh + 20vh sopra + 20vh sotto */
    /*background-image: url("../images/nivaz-header.png");*/
    background-image: url("../images/nivaz-header3.jpg");
    /*background-size: cover;*/
    background-position: top;
    /*background-repeat: no-repeat;*/
    opacity: 0.9;
    transform: translateY(var(--page-bg-offset));
    will-change: transform;
    filter: saturate(1.05) contrast(1.05);
    z-index: 0;
}

/* Glow/gradient sopra l’immagine (quello che avevi prima) */
.page-gradient-bg {
    position: fixed;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(circle at 10% 10%, rgba(255, 80, 100, 0.22) 0, transparent 50%), radial-gradient(circle at 85% 20%, rgba(160, 120, 255, 0.18) 0, transparent 55%);
    opacity: 0.85;
    mix-blend-mode: screen;
    z-index: -2; /* leggermente sopra l’immagine */
}

/* HEADER */

/* Bottone hamburger */
.menu-toggle {
    display: none; /* visibile solo su mobile */
    width: 34px;
    height: 30px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(8, 8, 16, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    gap: 4px;
    cursor: pointer;
    padding: 0 6px;
    color: var(--text-main);
}

.menu-line {
    width: 16px;
    height: 2px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.85);
    transition: transform var(--transition-fast), opacity var(--transition-fast);
}

/* stato "aperto" → animazione delle linee */
body.nav-open .menu-toggle .menu-line:nth-child(1) {
    transform: translateY(4px) rotate(45deg);
}

body.nav-open .menu-toggle .menu-line:nth-child(2) {
    opacity: 0;
}

body.nav-open .menu-toggle .menu-line:nth-child(3) {
    transform: translateY(-4px) rotate(-45deg);
}


.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 9vw 10px;
    backdrop-filter: blur(18px);
    background: linear-gradient(
        to bottom,
        rgba(5, 5, 12, 0.95),
        rgba(5, 5, 12, 0.85),
        transparent
    );
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
}

.logo-mark {
    width: 32px;
    height: 32px;
    border-radius: 12px;
    background: radial-gradient(circle at 30% 0, #ffd3d8, var(--accent));
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #280307;
    box-shadow:
        0 0 12px rgba(255, 80, 100, 0.7),
        0 10px 30px rgba(0, 0, 0, 0.7);
}

.logo-text {
    font-size: 15px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #ff5967;
}

.site-nav {
    display: flex;
    gap: 22px;
}

.site-nav a {
    font-size: 14px;
    text-decoration: none;
    color: var(--text-muted);
    position: relative;
    padding-bottom: 4px;
    transition: color var(--transition-fast);
}

.site-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0%;
    height: 2px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent), var(--accent-strong));
    transition: width var(--transition-med);
}

.site-nav a:hover {
    color: var(--text-main);
}

.site-nav a:hover::after {
    width: 55%;
}

/* SECTIONS */

.section {
    padding: 80px 9vw 60px;
    position: relative;
    z-index: 0;
}

    /* Pannello vetro satinato per le sezioni con .glass */
    .section.glass {
        background: rgba(7, 7, 16, 0.72); /* semi-trasparente */
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        border-top: 1px solid rgba(255, 255, 255, 0.04);
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        box-shadow: 0 22px 60px rgba(0, 0, 0, 0.85);
    }


.section-header {
    max-width: 720px;
    margin: 0 auto 40px;
    text-align: center;
}

.section-header h2 {
    font-size: 28px;
    margin-bottom: 8px;
}

.section-header p {
    margin: 0;
    color: var(--text-muted);
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1.8fr) minmax(0, 1.1fr);
    gap: 56px;
    align-items: center;
    padding-top: 70px;
    padding-bottom: 70px;
    position: relative;
    overflow: hidden;
    z-index: 0; 
}


    /* immagine NivaZ + overlay */
    /*.hero::before {
        content: "";
        position: absolute;
        inset: -60px 0 0 0;
        background-image: url("../images/nivaz-header.png");
        background-size: cover;
        background-position: top;
        background-repeat: no-repeat;
        transform: translateY(var(--hero-bg-offset));
        opacity: 1.0;
        filter: saturate(1.05) contrast(1.05);
        z-index: -1;*/ /* va bene così dentro la hero */
    /*}

    .hero::after {
        content: "";
        position: absolute;
        inset: 0;
        background: radial-gradient(circle at top, rgba(5, 10, 40, 0.85), rgba(5, 5, 10, 0.98));
        mix-blend-mode: multiply;
        z-index: -1;*/ /* sopra l’immagine, sotto il contenuto */
    /*}*/



.hero-kicker {
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 0.14em;
    color: var(--accent-strong);
    margin-bottom: 12px;
    text-shadow: 0 0 10px rgba(255, 48, 64, 0.4);
}


.hero-title {
    font-size: clamp(32px, 4vw, 40px);
    line-height: 1.2;
    margin: 0 0 16px;
}

.hero-subtitle {
    color: var(--text-muted);
    max-width: 540px;
    margin-bottom: 22px;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 18px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border-radius: var(--radius-pill);
    font-size: 14px;
    font-weight: 500;
    border: 1px solid transparent;
    cursor: pointer;
    text-decoration: none;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast);
}

    .btn.primary {
        background: radial-gradient(circle at top left, var(--accent-strong), var(--accent));
        color: #2b0208;
        /*box-shadow: 0 14px 30px rgba(0, 0, 0, 0.8);*/
        box-shadow: 0 0 18px rgba(255, 48, 64, 0.45), 0 14px 30px rgba(0, 0, 0, 0.8);
    }

.btn.primary:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.9);
}

.btn.ghost {
    background: rgba(10, 10, 18, 0.7);
    color: var(--text-main);
    border-color: rgba(255, 255, 255, 0.12);
}

.btn.ghost:hover {
    border-color: var(--accent-soft);
    background: rgba(15, 15, 30, 0.95);
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.meta-pill {
    font-size: 12px;
    padding: 5px 12px;
    border-radius: var(--radius-pill);
    border: 1px solid var(--border-subtle);
    background: rgba(14, 14, 20, 0.85);
    color: var(--text-muted);
}

/* HERO SIDE */

.hero-side {
    position: relative;
    min-height: 260px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-card {
    position: relative;
    z-index: 2;
    background: rgba(8, 8, 15, 0.96);
    border-radius: 20px;
    padding: 20px 22px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: var(--shadow-soft);
    max-width: 290px;
}

.hero-card-label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: var(--accent-strong);
    margin-bottom: 8px;
}

.hero-card-main {
    font-size: 18px;
    margin-bottom: 4px;
}

.hero-card-meta {
    font-size: 13px;
    color: var(--text-muted);
}

.floating {
    animation: floatCard 5s ease-in-out infinite;
}

@keyframes floatCard {
    0% { transform: translateY(0px) translateX(0px); }
    50% { transform: translateY(-10px) translateX(4px); }
    100% { transform: translateY(0px) translateX(0px); }
}

/* HERO ORBIT */

.hero-orbit {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    pointer-events: none;
}

.hero-orbit-ring {
    position: absolute;
    border-radius: 999px;
    border: 1px dashed rgba(255, 130, 150, 0.28);
    box-shadow: 0 0 40px rgba(255, 80, 100, 0.2);
    opacity: 0.8;
}

.hero-orbit-ring.ring-1 {
    width: 260px;
    height: 260px;
    animation: orbitRotate 16s linear infinite;
}

.hero-orbit-ring.ring-2 {
    width: 200px;
    height: 200px;
    animation: orbitRotate 22s linear infinite reverse;
}

.hero-orbit-ring.ring-3 {
    width: 140px;
    height: 140px;
    border-style: solid;
    border-color: rgba(180, 140, 255, 0.25);
    animation: orbitRotate 18s linear infinite;
}

@keyframes orbitRotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.hero-orbit-dot {
    position: absolute;
    width: 9px;
    height: 9px;
    border-radius: 999px;
    background: var(--accent);
    box-shadow: 0 0 14px rgba(255, 80, 100, 0.9);
}

.hero-orbit-dot.dot-1 {
    top: 12%;
    left: 54%;
    animation: orbitDot 11s linear infinite;
}

.hero-orbit-dot.dot-2 {
    bottom: 14%;
    right: 18%;
    background: #ffb347;
    box-shadow: 0 0 14px rgba(255, 179, 71, 0.9);
    animation: orbitDot 16s linear infinite reverse;
}

.hero-orbit-dot.dot-3 {
    bottom: 10%;
    left: 20%;
    background: #9f8bff;
    box-shadow: 0 0 16px rgba(159, 139, 255, 0.9);
    animation: orbitDot 20s linear infinite;
}

@keyframes orbitDot {
    0% { transform: translate(0, 0); }
    25% { transform: translate(-6px, 4px); }
    50% { transform: translate(2px, -5px); }
    75% { transform: translate(5px, 3px); }
    100% { transform: translate(0, 0); }
}

/* ABOUT */

.about-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.2fr);
    gap: 30px;
}

.about-text p {
    margin-bottom: 14px;
    color: var(--text-muted);
}

.about-text strong {
    color: var(--text-main);
}

.about-highlight {
    background: rgba(9, 9, 18, 0.95);
    border-radius: var(--radius-lg);
    padding: 18px 20px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: var(--shadow-soft);
}

.about-highlight h3 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 16px;
}

.about-highlight ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.about-highlight li {
    font-size: 14px;
    color: var(--text-muted);
    padding: 6px 0;
}

/* PROJECTS */

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.project-card {
    background: rgba(10, 10, 20, 0.96);
    border-radius: var(--radius-lg);
    padding: 18px 18px 20px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
    transform: translateY(10px);
    opacity: 0;
    transition:
        opacity 0.6s var(--transition-med),
        transform 0.6s var(--transition-med),
        border-color var(--transition-fast),
        box-shadow var(--transition-fast),
        background var(--transition-fast);
}

.project-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.project-card:hover {
    border-color: rgba(255, 80, 100, 0.55);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.85);
    background: radial-gradient(circle at top left,
        rgba(255, 80, 100, 0.1),
        rgba(10, 10, 20, 0.98)
    );
}

.project-tag {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: var(--accent-strong);
    margin-bottom: 10px;
}

.project-title {
    margin: 0 0 8px;
    font-size: 18px;
}

.project-description {
    margin: 0 0 14px;
    font-size: 14px;
    color: var(--text-muted);
}

.project-meta span {
    font-size: 12px;
    color: var(--text-muted);
    border-radius: var(--radius-pill);
    padding: 4px 10px;
    background: rgba(5, 5, 12, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

/* SKILLS */

.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.skills-column {
    background: rgba(8, 8, 16, 0.96);
    border-radius: var(--radius-lg);
    padding: 16px 18px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.skills-column h3 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 16px;
}

.skills-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.skills-column li {
    font-size: 14px;
    padding: 4px 0;
    color: var(--text-muted);
}

/* CONTACT */

.contact-panel {
    max-width: 620px;
    margin: 0 auto;
    background: rgba(7, 7, 14, 0.98);
    border-radius: 22px;
    padding: 24px 24px 26px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: var(--shadow-soft);
}

.contact-panel p {
    margin-top: 0;
    margin-bottom: 14px;
    color: var(--text-muted);
}

.contact-details {
    display: grid;
    gap: 10px;
}

.contact-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.contact-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: var(--text-muted);
}

.contact-item a {
    color: var(--accent-strong);
    text-decoration: none;
    font-size: 14px;
}

.contact-item a:hover {
    text-decoration: underline;
}

/* FOOTER */

.site-footer {
    padding: 18px 9vw 26px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    align-items: center;
    font-size: 13px;
    color: #ffffff;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background: radial-gradient(circle at top, rgba(10, 10, 20, 0.95), rgba(3, 3, 6, 0.98));
    z-index:20;
}

.footer-dot {
    font-size: 16px;
}

/* ANIMAZIONI ON SCROLL */

.reveal {
    opacity: 0;
    transform: translateY(18px);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
    transition:
        opacity 0.6s var(--transition-med),
        transform 0.6s var(--transition-med);
}

/* RESPONSIVE */

@media (max-width: 960px) {
    .hero {
        grid-template-columns: minmax(0, 1fr);
    }

    .hero-side {
        order: -1;
        margin-bottom: 10px;
    }

    .about-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .projects-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .skills-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .site-header {
        padding-inline: 5vw;
        gap: 18px;
    }
}

@media (max-width: 700px) {
    .site-header {
        padding-inline: 5vw;
        gap: 18px;
    }

    /* Mostra il bottone hamburger su mobile */
    .menu-toggle {
        display: inline-flex;
    }

    /* Nav mobile: overlay glass */
    .site-nav {
        position: fixed;
        top: 56px; /* circa l’altezza dell’header */
        right: 5vw;
        left: 5vw;
        padding: 14px 16px 16px;
        border-radius: 18px;
        background: rgba(7, 7, 18, 0.92);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border: 1px solid rgba(255, 255, 255, 0.08);
        box-shadow: 0 18px 40px rgba(0, 0, 0, 0.85);
        display: flex;
        flex-direction: column;
        gap: 10px;
        opacity: 0;
        pointer-events: none;
        transform: translateY(-10px);
        transition: opacity var(--transition-fast), transform var(--transition-fast);
        z-index: 40;
    }

    body.nav-open .site-nav {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }

    .site-nav a {
        padding: 4px 0;
        font-size: 15px;
    }

    /* il resto delle regole che avevi già */
    .section {
        padding-inline: 5vw;
    }

    .projects-grid,
    .skills-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .hero {
        padding-top: 50px;
    }

    /* Nascondi la card su mobile, mantieni l’orbita */
    .hero-card {
        display: none;
    }

    .hero-side {
        min-height: 220px; /* tieni comunque un po’ di spazio per l’orbita */
    }

}

.cv-wrapper {
    padding: 80px 9vw 60px;
    display: flex;
    justify-content: center;
}

.cv-page {
    background: #ffffff;
    color: var(--cv-text-main);
    max-width: 900px;
    width: 100%;
    border-radius: 26px;
    padding: 32px 40px 34px;
    box-shadow: 0 22px 70px rgba(0, 0, 0, 0.75);
    position: relative;
}

.cv-banner {
    background: linear-gradient(135deg, var(--cv-blue), var(--cv-blue-soft));
    border-radius: 20px;
    padding: 18px 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    color: #f8fafc;
    margin-bottom: 22px;
}

.cv-heading-main {
    display: flex;
    flex-direction: column;
    gap: 4px;
}


.cv-avatar-wrapper {
    flex-shrink: 0;
}

.cv-avatar-circle {
    min-width: 92px;
    min-height: 92px;
    border-radius: 999px;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cv-blue);
    font-weight: 700;
    font-size: 26px;
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.25), 0 12px 26px rgba(0, 0, 0, 0.45);
}

.cv-name {
    font-size: 26px;
    font-weight: 700;
    letter-spacing: 0.03em;
}

.cv-role {
    font-size: 15px;
    opacity: 0.9;
}

.cv-badge {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    opacity: 0.7;
}


.cv-avatar-cell {
    text-align: right;
    vertical-align: middle;
}


.cv-contact-strip {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    font-size: 13px;
}

.cv-contact-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.cv-contact-label {
    font-weight: 600;
}

.cv-contact-value a {
    color: #ffe6ea;
    text-decoration: none;
}

    .cv-contact-value a:hover {
        text-decoration: underline;
    }

/* Layout contenuto principale */
.cv-body {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 24px;
}

.cv-section-title {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--cv-blue);
    margin-bottom: 6px;
}

.cv-section-underline {
    width: 52px;
    height: 3px;
    border-radius: 999px;
    background: var(--cv-red);
    margin-bottom: 10px;
}

.cv-section {
    font-size: 13px;
    color: var(--cv-text-main);
    margin-bottom: 16px;
}

.cv-paragraph {
    margin: 0 0 6px;
    color: var(--cv-text-muted);
    line-height: 1.45;
}

/* Esperienze (timeline soft) */
.cv-job {
    margin-bottom: 12px;
    padding: 10px 12px;
    border-radius: 14px;
    background: var(--cv-blue-light);
}

.cv-job-header {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 4px;
}

.cv-job-title {
    font-weight: 600;
}

.cv-job-meta {
    font-size: 12px;
    color: var(--cv-text-muted);
    text-align: right;
    white-space: nowrap;
}

.cv-job-company {
    font-size: 10px;
    color: var(--cv-text-muted);
    margin-bottom: 4px;
    text-align: right;
    float:right;
}

.cv-list {
    margin: 0;
    padding-left: 18px;
    color: var(--cv-text-muted);
}

    .cv-list li {
        margin-bottom: 3px;
    }

/* Colonna destra: box tondeggianti */
.cv-side-card {
    background: var(--cv-blue-light);
    border-radius: 18px;
    padding: 12px 14px 10px;
    margin-bottom: 14px;
}

.cv-side-card-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--cv-blue);
    margin-bottom: 6px;
}

.cv-tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    font-size: 11px;
}

.cv-tag {
    padding: 4px 9px;
    border-radius: 999px;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.06);
    color: var(--cv-text-muted);
}

    .cv-tag.strong {
        background: var(--cv-blue);
        color: #ffffff;
        border-color: transparent;
    }

.cv-side-text {
    font-size: 11px;
    color: var(--cv-text-muted);
    margin: 0;
}

.cv-print-bar {
    position: absolute;
    top: -38px;
    right: 12px;
}

.cv-print-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 14px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.25);
    background: rgba(10, 10, 18, 0.96);
    color: #f5f5f7;
    cursor: pointer;
    font-size: 12px;
    text-decoration: none;
}

    .cv-print-button:hover {
        border-color: var(--cv-red);
    }

@page {
    size: A4;
    margin: 8mm 8mm; /* sopra/sotto 12mm, dx/sx 15mm */
}

@media print {
    * {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    html, body {
        margin: 0 !important;
        padding: 0 !important;
        background: #ffffff !important;
        height: auto !important;
        font-size: 0.65em !important;
    }

    .privacy {
        font-size: 0.7em !important;
    }

    body {
        min-height: 0 !important;
        overflow: visible !important;
    }

    .page-bg-image,
    .page-gradient-bg,
    .site-header,
    .site-footer,
    .cv-print-bar,
    .page-gradient-bg {
        display: none !important;
    }

    .cv-wrapper {
        padding: 0 !important;
    }

    .cv-page {
        box-shadow: none !important;
        border-radius: 0 !important;
        max-width: 100% !important;
        width: 100% !important;
        padding: 0 !important;
        margin: 0 auto !important;
        background: #ffffff !important;
        height: auto !important; /* nessun vincolo di altezza fissa */
        page-break-after: auto !important;
        break-after: auto !important;
    }

    .cv-body {
        display: grid !important;
        grid-template-columns: 1.5fr 1fr !important;
        gap: 24px !important;
    }

    .cv-job,
    .cv-side-card {
        page-break-inside: avoid;
        break-inside: avoid;
    }

    /* Volendo anche le sezioni intere */
    /*.cv-section {
                page-break-inside: avoid;
                break-inside: avoid;
            }*/
}



@media screen and (max-width: 960px) {
    .cv-page {
        padding: 26px 20px 24px;
    }

    .cv-body {
        grid-template-columns: 1fr;
    }

    .cv-banner {
        flex-direction: column;
        align-items: flex-start;
    }

    .cv-avatar-wrapper {
        align-self: flex-end; /* avatar in alto a destra su mobile */
        margin-top: 8px;
    }

    /*.cv-avatar-circle {
                align-self: flex-end;
            }
*/
    .cv-print-bar {
        position: static;
        margin-bottom: 10px;
        text-align: right;
    }
}