body {
    background-color: #1a1a1a;
    color: #00ff00;
    font-family: 'Fira Code', monospace;
    font-size: 16px;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    overflow: hidden;
}

#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease-out;
}

#preloader img {
    max-width: 289px;
    height: auto;
    margin-bottom: 20px;
}

.progress-container {
    display: flex;
    align-items: center;
    font-family: 'Fira Code', monospace;
    font-size: 24px;
    margin-top:25px;
    color: #ffffff;
}

#progress-bar {
    letter-spacing: 0;
}

.terminal {
    width: 80%;
    max-width: 1000px;
    height: 480px;
    background-color: #00000075;
    border: 1px solid #333;
    border-radius: 5px;
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.5s ease-in, transform 0.5s ease-in;
    display: flex;
    flex-direction: column;
    z-index: 1;
}

.terminal-header {
    background-color: #2c2c2c;
    padding: 8px;
    display: flex;
    align-items: center;
}

.terminal-buttons {
    display: flex;
}

.button {
    height: 12px;
    width: 12px;
    border-radius: 50%;
    margin-right: 8px;
}

.button.red { background-color: #ff5f56; }
.button.yellow { background-color: #ffbd2e; }
.button.green { background-color: #27c93f; }

.terminal-title {
    color: #eee;
    font-weight: bold;
    flex-grow: 1;
    text-align: center;
}

.terminal-body {
    padding: 20px;
    padding-top: 12px;
    padding-bottom: 12px;
    line-height: 1.6;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

.command-block, #final-prompt {
    display: none;
    margin: 5px 0px;
}

.command-line {
    margin: 5px 0px;
}

.prompt {
    color: #00ff00;
    font-weight: bold;
}

.output {
    margin-top: 10px;
    color: #ccc;
    display: none; /* Hide output by default */
}

pre.output {
    white-space: pre-wrap;
    word-wrap: break-word;
}

.output-skills {
    flex-wrap: wrap;
    column-gap: 15px;
}

.output-skills span {
    background-color: #33333300;
    padding: 2px 0px;
    border-radius: 3px;
}

a {
    color: #ff7d11;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.cursor, .cursor-command {
    display: inline-block;
    width: 10px;
    height: 1em;
    background-color: #00ff00;
    animation: blink 1s step-end infinite;
    vertical-align: -2px;
}

@keyframes blink {
    from, to { background-color: transparent; }
    50% { background-color: #00ff00; }
}

/* Desktop Icons */
.desktop-icons {
    position: fixed;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 20px;
    z-index: 2;
}

.desktop-icon {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px;
    color: #ffffff;
    text-decoration: none;
    transition: all 0.3s ease;
    border-radius: 8px;
    background-color: transparent;
}

.desktop-icon:hover {
    background-color: #00ff0020;
}

.desktop-icon svg {
    width: 32px;
    height: 32px;
}

.desktop-icon span {
    font-size: 12px;
    font-family: 'Fira Code', monospace;
    white-space: nowrap;
}

/* Tablet adaptation */
@media screen and (max-width: 1024px) {
    #preloader img {
        max-width: 289px;
    }

    .progress-container {
        font-size: 20px;
    }

    .desktop-icons {
        left: 10px;
        gap: 15px;
    }

    .desktop-icon svg {
        width: 28px;
        height: 28px;
    }

    .terminal {
        width: 75%;
        max-width: 75%;
        height: 90%;
        margin-left: 0;
    }
    
    .terminal-body {
        padding: 15px;
    }
}

/* Mobile adaptation */
@media screen and (max-width: 768px) {
    #preloader img {
        max-width: 289px;
    }

    .progress-container {
        font-size: 16px;
    }

    /* Move icons to dock bar at bottom */
    .desktop-icons {
        position: fixed;
        left: 50%;
        top: auto;
        bottom: 20px;
        transform: translateX(-50%);
        flex-direction: row;
        gap: 20px;
        background-color: #2c2c2c;
        padding: 10px 20px;
        border-radius: 20px;
        border: 1px solid #333;
    }

    .desktop-icon span {
        display: none;
    }

    .desktop-icon {
        padding: 8px;
    }

    .desktop-icon svg {
        width: 24px;
        height: 24px;
    }

    body {
        font-size: 14px;
    }
    
    .terminal {
        width: 100%;
        max-width: 100%;
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
        border: none;
        margin-left: 0;
    }
    
    .terminal-header {
        border-radius: 0;
    }
    
    .terminal-body {
        padding: 15px;
        padding-top: 10px;
        padding-bottom: 10px;
    }
    
    .button {
        height: 10px;
        width: 10px;
    }
    
    .terminal-title {
        font-size: 14px;
    }
    
    /* Disable pre-wrap for contacts block */
    #block-3 pre.output {
        white-space: pre;
        overflow-x: auto;
    }
}

/* Small mobile devices */
@media screen and (max-width: 480px) {
    #preloader img {
        max-width: 289px;
    }

    .progress-container {
        font-size: 18px;
    }

    .desktop-icons {
        bottom: 15px;
        gap: 15px;
        padding: 8px 15px;
    }

    .desktop-icon {
        padding: 6px;
    }

    .desktop-icon svg {
        width: 30px;
        height: 30px;
    }

    body {
        font-size: 12px;
    }

    .terminal {
        margin-left: 0;
    }
    
    .terminal-body {
        padding: 10px;
    }
    
    .terminal-title {
        font-size: 12px;
    }
    
    .button {
        height: 8px;
        width: 8px;
        margin-right: 6px;
    }
}
