/* ==========================================================================
   1. ESTILOS GENERALES Y BASE
   ========================================================================== */
* {
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    background-color: #ffffff;
}

body {
    font-family: monospace;
    position: relative;
    overflow-x: hidden;
    overflow-y: auto;
}

h1, h3 {
    text-align: center;
    font-family: "Comfortaa", serif;
    font-weight: 700;
}

.fuente {
    font-family: monospace;
    font-weight: 300;
}

/* ==========================================================================
   2. CONTENEDOR PRINCIPAL Y LAYOUT (DESKTOP)
   ========================================================================== */
.container {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    min-height: 100vh;
    padding: 20px;
}

.interactables {
    display: flex;
    align-items: center; 
    justify-content: center;
    gap: 30px;
    width: 100%;
    max-width: 1100px;
}

.disclaimer {
    margin-top: 40px;
    font-family: monospace;
    font-weight: 300;
    color: #fc2887;
}

/* ==========================================================================
   3. ELEMENTOS INTERACTIVOS (PC, DVD Y PORTADA)
   ========================================================================== */
.computer {
    position: relative;
    width: 100%;
    max-width: 650px; 
    margin: 0 auto;
}

.computer img {
    width: 100%;
    height: auto;
    display: block;
}

#floppy {
    width: 105px;
    cursor: pointer;
    z-index: 10;
}

#computer-area {
    position: absolute;
    bottom: 50%;
    right: 25%;
    width: 70px;
    height: 50px;
    background: none;
    z-index: 5;
}

.dropped-floppy {
    position: absolute;   
    right: 46%;
    bottom: 4%; 
    display: none;
    z-index: 2;
}

.dropped-floppy img {
    width: 135px;
}

.computer-mask {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

#devlog {
    width: 230px;
    cursor: pointer;
    transition: transform 0.4s ease-in-out;
}

#devlog:hover {
    transform: translateY(-20px);
}

/* ==========================================================================
   4. SECCIÓN DEL DEVLOG / ANÁLISIS (PANEL DESPLEGABLE)
   ========================================================================== */
.devlog-container {
    position: absolute;
    bottom: -100vh;
    width: 100%;
    height: 500px;
    max-height: 100%;
    padding: 10px;
    transition: bottom 1s ease-out;
    z-index: 100;
}

.devlog-container.open {
    bottom: 0;
}

.devlog-content {
    font-family: "Source Sans Pro", sans-serif;
    background-color: #fff8e9;
    padding: 20px;
    width: 100%;
    max-width: 830px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
}

.devlog-content h1 {
    color: #ff80b2;
    margin-top: 0;
}

.devlog-content h3 {
    text-align: left;
    font-family: "Source Sans Pro", sans-serif;
    font-weight: bold;
    margin-bottom: 5px;
    color: #ff80b2;
}

.devlog-list {
    width: 100%;
    overflow-y: auto;
}

.devlog-item {
    width: 100%;
    border-top: dotted 3px lightgray;
    padding-top: 10px;
}

.round-border {
    border: solid 4px #181425;
    border-radius: 10px;
    box-shadow: 4px 4px 0px -1px rgba(24, 20, 37, 1);
}

.devlog-close {
    border-radius: 50px;
    height: 50px;
    width: 50px;
    font-size: 1.5em;
    position: absolute;
    right: -20px;
    top: -20px;
    background-color: #ffd5e5;
    cursor: pointer;
    transition: background-color 0.2s ease-in-out;
    display: flex;
    justify-content: center;
    align-items: center;
}

.devlog-close:hover {
    background-color: #ff80b2;
}

/* ==========================================================================
   5. TRANSICIONES Y ANIMACIONES
   ========================================================================== */
.transition {
    background-color: #fdcee8;
    position: absolute;
    top: 33%;
    left: 25%;
    width: 50px;
    height: 50px;
    border-radius: 100%;
    transform: scale(0);
    z-index: 99;
}

.transition-animate {
    animation: transition 1s ease-in-out forwards;
}

.hidden {
    opacity: 0;
}

.display {
    display: block;
}

.animation {
    top: auto !important;
    left: auto !important;
    animation: insertDisk 1s ease-in-out forwards;
}

@keyframes insertDisk {
    0% {
        transform: translate(0, 0) scale(1);
        opacity: 1;
    }
    100% {
        transform: translate(-50px, -30px) scale(0.9); 
        opacity: 0.2;
    }
}

@keyframes transition {
    0% {
        transform: scale(1);
        background-color: #fdcee8;
    }
    50% {
        background-color: #adadad;
    }
    100% {
        transform: scale(500);
        background-color: #000000;
    }
}

/* ==========================================================================
   6. RESPONSIVE DESIGN (PANTALLAS CHICAS / CELULARES)
   ========================================================================== */
@media screen and (max-width: 768px) {
    .container {
        font-size: 0.75em; 
        padding: 5px;
    }

    /* Mantenemos la estructura horizontal intacta */
    .interactables {
        flex-direction: row; 
        gap: 0px;
        width: 100%;
        padding: 0 5px;
    }

    .computer {
        width: 62%;
        max-width: none;
    }

    /* PORTADA DEL DVD: La adaptamos y la movemos hacia abajo */
    #devlog {
        width: 25%;
        max-width: 70px;
        transform: translateY(10px);
        transition: none; 
    }
    #devlog:hover {
        transform: translateY(50px); 
    }

    /* EL DVD (DISQUETE): Lo adaptamos y también lo tiramos un toque hacia abajo */
    #floppy {
        width: 15%;
        max-width: 45px;
        transform: translateY(35px);
    }

    /* Zona de soltado adaptada milimétricamente al tamaño móvil de la PC */
    #computer-area {
        width: 18%;
        height: 14%;
        bottom: 49%;
        right: 24%;
    }

    .dropped-floppy img {
        width: 55px;
    }

    .disclaimer {
        font-size: 1.1em;
        margin-top: 20px;
        padding: 0 10px;
    }

    /* Panel de análisis desplegable en móviles */
    .devlog-container {
        height: 80vh;
        padding: 5px;
    }

    .devlog-content {
        padding: 15px;
    }

    .devlog-close {
        right: 5px;
        top: 5px;
        width: 40px;
        height: 40px;
        font-size: 1.2em;
    }
}