/* Stile generale */
body {
    font-family: 'Roboto', sans-serif;
    color: #ffffff;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    background: #1e1e1e;
}

header {
    background-color: rgba(18, 18, 18, 0.8);
    padding: 20px;
    text-align: center;
    position: relative;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    z-index: 2;
}

h1 {
    margin: 0;
    font-size: 3rem; /* Dimensione del font aumentata */
    font-weight: 700;
    color: #007BFF;
    font-family: 'Montserrat', sans-serif; /* Nuovo font per il titolo */
}

.cv-button {
    position: absolute;
    top: 20px;
    right: 20px;
    background-color: #007BFF;
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease, transform 0.3s ease;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 10px;
}

.cv-button:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
}

.cv-button i {
    font-size: 1.2rem;
}

/* Stile tab */
.tabs {
    margin: 20px auto;
    max-width: 800px;
    position: relative;
    z-index: 2;
}

.tab {
    position: relative;
    margin-bottom: 10px;
    background-color: rgba(44, 44, 44, 0.8);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.tab:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
}

.tab input[type="radio"] {
    display: none;
}

.tab label {
    display: block;
    color: white;
    padding: 15px 20px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    font-weight: bold;
    font-size: 1.1rem;
    position: relative;
    z-index: 1;
    overflow: hidden; /* Per contenere l'immagine blurrata */
}

.tab .tab-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    filter: blur(4px); /* Solo l'immagine è blurrata */
    z-index: -1; /* Manda l'immagine dietro al testo */
}

.tab .tab-text {
    position: relative;
    z-index: 2;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.tab label:hover {
    opacity: 0.9;
}

.tab .content {
    display: none;
    padding: 20px;
    background-size: cover;
    background-position: center;
    border-radius: 0 0 10px 10px;
    animation: slideDown 0.5s ease-in-out;
    position: relative;
    z-index: 0;
}

@keyframes slideDown {
    0% {
        opacity: 0;
        transform: translateY(-20px);
    }
    50% {
        opacity: 1;
        transform: translateY(10px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    0% {
        opacity: 1;
        transform: translateY(0);
    }
    50% {
        opacity: 0.5;
        transform: translateY(10px);
    }
    100% {
        opacity: 0;
        transform: translateY(-20px);
    }
}

.tab input[type="radio"]:checked + label {
    border-radius: 10px 10px 0 0;
}

.tab input[type="radio"]:checked + label + .content {
    display: block;
}

.tab input[type="radio"]:not(:checked) + label + .content {
    animation: slideUp 0.5s ease-in-out;
}

.details {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

video {
    max-width: 300px;
    border-radius: 10px;
    background-color: #000;
}

.description {
    flex: 1;
}

p {
    font-size: 1rem;
    line-height: 1.6;
    margin: 0;
    background-color: rgba(0, 0, 0, 0.7);
    padding: 10px;
    border-radius: 5px;
}

p strong {
    font-weight: 700;
    color: #007BFF;
}

.github-link {
    display: inline-block;
    background-color: #007BFF;
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
    margin-top: 10px;
    transition: background-color 0.3s ease;
}

.github-link:hover {
    background-color: #0056b3;
}

.github-link i {
    margin-right: 10px;
}

.contributo {
    display: none;
}

/* Footer con transizione morbida */
footer {
    background-color: rgba(18, 18, 18, 0.8);
    color: #ffffff;
    text-align: center;
    padding: 10px 0;
    margin-top: 20px;
    box-shadow: 0 -4px 8px rgba(0, 0, 0, 0.3);
    position: relative;
    z-index: 2;
    transition: transform 0.5s ease-in-out;
}

/* Effetto luce del mouse */
.mouse-light {
    position: fixed;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(0, 123, 255, 0.3), rgba(0, 123, 255, 0));
    border-radius: 50%;
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Effetto background dinamico */
#background-effect {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(135deg, #1e1e1e, #2c3e50);
    animation: gradientAnimation 10s ease infinite;
}

@keyframes gradientAnimation {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Effetto particelle */
.particle {
    position: absolute;
    width: 10px;
    height: 10px;
    background-color: rgba(0, 123, 255, 0.5);
    border-radius: 50%;
    animation: float linear infinite;
}

@keyframes float {
    0% {
        transform: translateY(0) translateX(0);
    }
    50% {
        transform: translateY(-50vh) translateX(50vw);
    }
    100% {
        transform: translateY(-100vh) translateX(100vw);
    }
}
