body {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px 20px 40px 20px;
    font-family: monospace;
    background-color: #0a0a0a;
    color: #e0e0e0;
    line-height: 1.6;
    font-size: 16px;
    z-index: 1;
    overflow-x: hidden;
}

h2 {
    font-size: 1.3em;
    margin-top: 0;
    margin-bottom: 15px;
    color: #b180ff;
}

p {
    margin: 10px 0;
}

section {
    background-color: #1a1a1a;
    border: 2px solid #444;
    padding: 25px;
    margin-bottom: 30px;
    transition: border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

section:hover {
    border-color: #b180ff;
    transform: translateY(-3px);
    box-shadow: 0 6px 0 rgba(177, 128, 255, 0.15);
}

section:last-child {
    margin-bottom: 0;
}

ul {
    list-style: none;
    padding-left: 0;
}

li {
    padding: 8px 0;
    padding-left: 20px;
}

a {
    color: #b180ff;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-bottom 0.2s, padding-left 0.2s;
}

a:hover {
    border-bottom: 1px solid #b180ff;
    padding-left: 4px;
}

footer {
    margin-top: 60px;
    padding-top: 30px;
    border-top: 1px solid #333;
    text-align: center;
    color: #666;
    font-size: 0.9em;
}

.grid-container {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 30px;
    margin-bottom: 30px;
    align-items: start;
}

.left-column section {
    margin-bottom: 30px;
}

.left-column section:last-child {
    margin-bottom: 0;
}

.right-column section {
    margin-bottom: 30px;
}

.right-column section:last-child {
    margin-bottom: 0;
}

.visitor-counter {
    text-align: left;
    margin-top: 30px;
}

.visitor-counter img {
    display: block;
}

.projects {
    background-color: #1a1a1a;
    border: 2px solid #444;
    padding: 25px;
    margin-bottom: 30px;
}

.project-item {
    margin-bottom: 20px;
}

.project-item:last-child {
    margin-bottom: 0;
}

.project-item h3 {
    color: #b180ff;
    margin-bottom: 5px;
}

/* logo */
.ascii-title {
    text-align: center;
    color: #b180ff;
    font-size: 0.6em;
    margin-bottom: 15px;
    margin-top: 0;
    line-height: 1;
    font-weight: bold;
    text-shadow: 0 0 6px rgba(177, 128, 255, 0.4), 0 0 16px rgba(177, 128, 255, 0.25);
    animation: neon-flicker 5s infinite;
    cursor: default;
}

@keyframes neon-flicker {
    0%, 19%, 21%, 23%, 54%, 56%, 100% {
        opacity: 1;
        text-shadow: 0 0 6px rgba(177, 128, 255, 0.4), 0 0 16px rgba(177, 128, 255, 0.25);
    }
    20%, 22%, 55% {
        opacity: 0.55;
        text-shadow: none;
    }
}

.ascii-title.power-flicker {
    animation: power-flicker 0.35s linear;
}

@keyframes power-flicker {
    0%   { opacity: 1; }
    10%  { opacity: 0.3; }
    20%  { opacity: 1; }
    30%  { opacity: 0.5; }
    40%  { opacity: 1; }
    100% { opacity: 1; }
}

.ascii-title:hover {
    animation: glitch 0.3s steps(2) 2;
}

@keyframes glitch {
    0% { text-shadow: 2px 0 #ff4d9d, -2px 0 #4dd9ff; }
    50% { text-shadow: -2px 0 #ff4d9d, 2px 0 #4dd9ff; }
    100% { text-shadow: 0 0 16px rgba(177, 128, 255, 0.7); }
}

.retro-badges {
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    margin: 25px 0 40px 0;
}

.retro-badge {
    width: 88px;
    height: 31px;
    background-color: #1a1a1a;
    border: 1px solid #b180ff;
    color: #b180ff;
    font-size: 9px;
    line-height: 1.1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    letter-spacing: 0.5px;
    image-rendering: pixelated;
}

.retro-badge strong {
    font-size: 10px;
}
    text-align: center;
    margin-bottom: 25px;
}

.badge {
    background-color: #1a1a1a;
    border: 2px dashed #b180ff;
    padding: 10px 20px;
    display: inline-block;
    font-size: 0.9em;
    color: #b180ff;
    animation: blink 2s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.now-playing {
    margin-bottom: 0;
}

.music-container {
    display: flex;
    gap: 15px;
    align-items: center;
}

.album-art {
    width: 64px;
    height: 64px;
    border: 2px solid #444;
    display: none;
}

.album-art.loaded {
    display: block;
}

.track-details {
    flex: 1;
}

.music-status {
    color: #b180ff;
    font-size: 0.9em;
    margin-bottom: 5px;
}

.track-info {
    color: #e0e0e0;
    font-size: 0.95em;
}

/* comete */
.stars-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

/* scanline */
.scanlines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2;
    background: repeating-linear-gradient(
        to bottom,
        rgba(255, 255, 255, 0.025) 0px,
        rgba(255, 255, 255, 0.025) 1px,
        transparent 1px,
        transparent 3px
    );
    animation: flicker 6s infinite;
}

@keyframes flicker {
    0%, 96%, 100% { opacity: 1; }
    97% { opacity: 0.94; }
    98% { opacity: 1; }
    99% { opacity: 0.97; }
}

/* animazione inizio */
.boot-overlay {
    position: fixed;
    inset: 0;
    background-color: var(--color-bg, #0a0a0a);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    transition: opacity 0.6s ease;
}

.boot-overlay.boot-done {
    opacity: 0;
    pointer-events: none;
}

.boot-terminal {
    width: 100%;
    max-width: 560px;
    max-height: 70vh;
    overflow-y: auto;
    font-size: 0.9em;
    line-height: 1.65;
    scrollbar-width: none;
}

.boot-terminal::-webkit-scrollbar {
    display: none;
}

.boot-line .prompt {
    color: #b180ff;
}

.boot-line .cmd {
    color: #e0e0e0;
}

.boot-output {
    color: #7a7a7a;
    margin: 0 0 14px 0;
}

.boot-output.boot-log div {
    color: #6edcab;
}

.boot-terminal .cursor {
    display: inline-block;
    background-color: #b180ff;
    width: 8px;
    height: 1em;
    vertical-align: middle;
    animation: blink-cursor 1s steps(1) infinite;
}

@keyframes blink-cursor {
    0%, 49% { opacity: 1; }
    50%, 100% { opacity: 0; }
}

.star {
    position: absolute;
    color: #b180ff;
    font-size: 16px;
    opacity: 0;
    animation: shooting-star 3s linear infinite;
}

@keyframes shooting-star {
    0% {
        transform: translate(0, 0) rotate(-45deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translate(140px, 140px) rotate(-45deg);
        opacity: 0;
    }
}

.ascii-footer {
    text-align: left;
    color: #444;
    font-size: 0.46vw;
    line-height: 1;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    padding: 0;
    white-space: pre;
}





@media (max-width: 768px) {
    body {
        padding: 20px 15px;
    }
    
    h1 {
        font-size: 2em;
    }
    
    h2 {
        font-size: 1.2em;
    }
    
    section {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .grid-container {
        grid-template-columns: 1fr;
    }
    
    .visitor-counter {
        margin-top: 0;
    }
}