:root {
    --color-bg: #edc4ffa2;
    --color-active: #ffcbeb8d;
    --color-near: #ffcdee4b;
}

/*fondo*/
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    background: linear-gradient(to bottom right, rgb(249, 164, 53), rgb(250, 63, 110));
    background-attachment: fixed;
    min-height: 100vh;
    overflow: hidden;
    font-family: 'Press Start 2P', cursive;
}

#container {
    display: grid;
    grid-template-columns: repeat(40, 1fr);
    width: 100vw;
    height: 100vh;
    z-index: 1;
    top: 0;
    gap: 0px;
    left: 0;
    position: absolute;
}

#container span {
    aspect-ratio: 1 / 1;
    background-color: rgba(241, 9, 9, 0.1);
    transition: background-color 0.3s ease;
    border: 1px solid #0022053d;
    border-radius: 5px;
    box-sizing: border-box;
}

#container span.active {
    background-color: var(--color-active);
    transition: background-color 0s;
}

#container span.near {
    background-color: var(--color-near);
}

.shadow-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    pointer-events: none;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.7) 100%);
    z-index: 2;
}


/*inicio*/
.press-start-2p-regular {
  font-family: "Press Start 2P", system-ui;
  font-weight: 400;
  font-style: normal;
}

.start-window {
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    background: rgba(255, 159, 159, 0.13); 
    color: white;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    z-index: 1000;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

@keyframes slideUp {
    from { transform: translate(-50%, -50%); }
    to { transform: translate(-50%, -250%); }
}

.slide-up {
    animation: slideUp 0.6s ease-in-out forwards;
}

.arrow-down {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 40px;
    color: rgba(255, 255, 255, 0.493);
    animation: pulse 1.5s infinite;
    cursor: pointer;
}

@keyframes pulse {
    0% { transform: translateY(0); opacity: 1; }
    50% { transform: translateY(1opx); opacity: 0.7; }
    100% { transform: translateY(0); opacity: 1; }
}

/*secciones*/
#window-manager {
    position: absolute;
    top: 50px;
    left: 50px;
    width: 100%;
    height: 100%;
    pointer-events: none; 
    z-index: 900;
}

.window {
    position: absolute; 
    top: 100px; 
    left: 100px;
    z-index: 3;
    width: 600px; 
    height: 400px; 
    background: #ba9eb490; 
    border: 1px solid #444;
    color: white; 
    border-radius: 8px;
}

.window p {
    margin: 10px;
    font-size: smaller;
}

.title-bar { 
    padding: 10px; 
    background: #333333ad; 
    font-weight: bold; 
}

.sticker {
    position: absolute;
    top: 200px;
    left: 300px;
    width: 160px;
    background: none;
    cursor: grab;
    z-index: 10;
    filter: drop-shadow(7px 7px 4px rgba(0,0,0,0.5));
}

.sticker:hover {
    filter: drop-shadow(10px 10px 4px rgba(0,0,0,0.6)); 
}
.sticker img { 
    width: 200px; 
    display: block; 
}

.sticker span { 
    display: none;
}

.image-container, .image-container-s {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-left: 15px; 
    padding-right: 15px;
    padding-bottom: 10px;
    width: 90%;
    gap: 5px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.image-container::-webkit-scrollbar {
    display: none;
}

.image-container img {
    flex: 0 0 80%;
    width: auto;
    max-width: 160px;          
    height: auto;
    object-fit: cover;
    scroll-snap-align: center;
    border-radius: 10px;
    border: 5px solid black;

    scroll-snap-align: start;
    scroll-snap-stop: always;
}

.image-container-s img {
    flex: 0 0 80%;
    width: auto;
    max-width: 250px;          
    height: auto;
    object-fit: cover;
    scroll-snap-align: center;
    border-radius: 10px;
    border: 5px solid black;

    scroll-snap-align: start;
    scroll-snap-stop: always;
}

.carrete-info {
    font-size: 8px;
    color: #666;
    text-align: center;
    margin-top: 5px;
}

.local-window {
    pointer-events: auto;
    display: none;
    width: 800px;
    height: 600px;
    min-height: 400px;
    background: #f7dadaf1;
    border: 3px solid #333;
    box-shadow: 8px 8px 0px rgba(0,0,0,0.2);
    z-index: 10000;
    padding: 10px;
    font-family: 'Press Start 2P', cursive;
    touch-action: none;
    user-select: none;
    border-radius: 10px;
}

.local-window .title-bar {
    border-radius: 5px;
    cursor: move;
    background: rgba(0, 0, 0, 0.738);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 7px;
    font-size: 13px;
    height: 30px;
}

.local-window .content {
    padding: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.local-window .content iframe {
    display: block;
    border: none;
    width: 80%;
    height: 350px;
    max-height: 360px;   
}

.local-window .content img {
    width: 600px;
    margin-top: 10px;
    border-radius: 10px;
    border: 4px solid rgba(30, 30, 30, 0.547);
}

.local-window button {
    pointer-events: auto;
    cursor: pointer;
    z-index: 1100;
    position: relative;
    background: #ffcccc;
    border: 1px solid #000;
    border-radius: 9px;
    border: 2px solid rgba(255, 255, 255, 0.44);
}

.btn-jugar {
    display: inline-block;
    margin-top: 15px;
    padding: 10px;
    background: #ffcbeb;
    color: #333;
    text-decoration: none;
    font-size: 10px;
    border: 2px solid #333;
}

.local-window .content-s {
    padding: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.local-window .content-s img {
    width: 600px;
    margin-top: 70px;
    border-radius: 10px;
    border: 4px solid rgba(30, 30, 30, 0.547);
}

/*barra superior*/
#top-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 45px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    padding: 0 20px;
    color: white;
    font-size: 15px;
    z-index: 100;
    justify-content: space-between;
}

/*dia y hora*/
#date-time {
    margin-left: auto;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 15px; 
}

#date-time span {
    background: rgba(0, 0, 0, 0.1);
    border: 5px solid rgba(0, 0, 0, 0.02);
    border-radius: 5px;
}

#time {
    margin-right: 50px;
}

/*clima*/
#weather {
    font-size: 27px;
    margin-bottom: 3px;
    cursor: pointer;
}

.weather-icon {
    width: 150px; 
    height: 150px;
    display: block; 
    margin-left: 10px;
    filter: drop-shadow(2px 2px 0px rgba(0,0,0,0.2));
}

.local-window-w .content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.local-window-w .content img {
    width: auto;
}

.local-window-w {
    pointer-events: auto;
    display: none;
    width: 500px;
    height: 400px;
    min-height: 400px;
    background: #f7dadaf1;
    border: 3px solid #333;
    box-shadow: 8px 8px 0px rgba(0,0,0,0.2);
    z-index: 10000;
    padding: 10px;
    font-family: 'Press Start 2P', cursive;
    touch-action: none;
    user-select: none;
    border-radius: 10px;
}

.local-window-w .title-bar {
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.738);
    color: white;
    display: flex;
    align-items: center;
    padding: 9px;
    font-size: 13px;
    height: 30px;
    justify-content: space-between;
}

.local-window-w .title-bar button {
    border-radius: 9px;
    border: 2px solid rgba(255, 255, 255, 0.44);
    background: rgba(255, 255, 255, 0.834);
    cursor: pointer;
}

/*sist info*/
#system-info {
    font-size: 30px;
    margin-bottom: 3px;
    cursor: pointer;
    margin-right: 3px;
}

#system-info:hover {
    color: rgb(155, 102, 2);
}

/*bottom bar*/
#bottom-bar {
    justify-content: center;
    position: fixed;
    bottom: 20px;
    left: 30%;
    right: 30%;
    border-radius: 30px;
    height: 75px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    padding: 0 20px;
    color: white;
    font-size: 15px;
    z-index: 100; 
}

#bottom-bar .app {
    cursor: pointer;
    transition: transform 0.2s;
    margin: 10px;
}

#bottom-bar .app:hover {
    transform: translateY(-5px); 
}

.app-active::after {
    content: "●";
    display: block;
    font-size: 10px;
    text-align: center;
}

.app img {
    width: 60px;
}

#window-spotify .content {
    display: block;
    overflow-y: auto;
    max-height: 500px;
}

/*pixel art*/
#pixel-canvas {
    display: grid;
    grid-template-columns: repeat(30, 20px); 
    grid-template-rows: repeat(20, 20px);    
    border: 2px solid #333;    
    border: 1px solid #999;
}

#pixel-canvas span {
    width: 20px;
    height: 20px;
    background-color: white;
    border: 1px solid #eee;
    box-sizing: border-box;
    cursor: pointer;
}

.pixel-editor-controls {
    margin-bottom: 10px;
}



/*calculadora*/
#calcu {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
}

#calcu-display {
    background: #1e1e1e;
    color: white;
    font-size: 40px;
    text-align: right;
    padding: 20px 25px;
    min-height: 80px;
    word-break: break-all;
    border-bottom: 1px solid #333;
    border-radius: 10px 10px 0 0;
    margin-top: 20px;
    margin-left: 15px;
    margin-right: 15px;
}

#calcu-buttons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: #333;
    flex: 1;
    border-radius: 0 0 10px 10px;
    margin-left: 15px;
    margin-right: 15px;
}

.calcu-btn {
    background: #2d2d2d;
    color: white;
    border: none;
    font-size: 20px;
    cursor: pointer;
    padding: 25px;
    font-family: 'Press Start 2P', cursive;
    transition: background 0.1s;
}

.calcu-btn:hover {
    background: #ffb5b5e4;
}

.calcu-btn:active {
    background: #ff87a1;
}

.calcu-btn.equal {
    background: #fc8aa3;
    color: white;
}

.calcu-btn.equal:hover {
    background: #ff8fa4ea;
}

.calcu-btn.span2 {
    grid-column: span 2;
}

#window-calcu {
    width: 450px;
    height: 600px;
}

/*space jump*/
#canvas1 {
    z-index: 99999999;
}

.local-window .content-sj {
    margin-top: 10px;
    width: 100%;
    padding: 0;
    height: calc(100% - 50px);
    overflow: hidden;
    text-align: center;
}

.local-window .content-sj iframe {
    border-radius: 10px;
    display: block;
    border: none;
    width: 100%;
    height: 100%;
    margin: 0;
}

#window-spaceJump {
    height: 620px;
}

/*notas*/
#notas-content { 
    padding: 10px; 
}

.todo-input-container { 
    display: flex; 
    gap: 5px; 
    margin-bottom: 10px; 
}

.todo-input-container button {
    font-size: 20px;
}

#todo-input {
    border: 2px solid #333;
    padding: 5px;
    font-family: 'Press Start 2P', cursive; 
    border-radius: 5px;
}

#todo-list { 
    list-style: none; 
    padding: 0; 
}

#todo-list li {
    background: #fff0f5;
    border: 1px solid #ffb6c1;
    margin-bottom: 5px;
    padding: 5px;
    display: flex;
    justify-content: space-between;
    font-family: 'Press Start 2P', cursive;
    font-size: 12px;
    align-items: center;
    width: 500px;
    border-radius: 5px;
}

#clear-all-btn {
    margin-top: 10px;
    width: 20%;
    padding: 10px;
    background-color: #ffcccc; 
    border: 1px solid #ff9999;
    cursor: pointer;
    font-family: 'Press Start 2P', cursive;
    font-size: 12px;
}

#clear-all-btn:hover {
    background-color: #ff9999;
}

/*yo*/

.local-window .content-yo {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.local-window .content-yo img {
    width: 400px;
    border-radius: 10px;
    border: 4px solid rgba(30, 30, 30, 0.547);
}
