/* Общие стили и сброс */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Press Start 2P', cursive; background-color: #000; overflow: hidden; color: white; }

/* Экран загрузки */
#loading-screen { position: fixed; top: 0; left: 0; width: 100%; height: 100vh; background-color: #000; display: flex; justify-content: center; align-items: center; z-index: 100; transition: opacity 1s ease-out; color: #00FF00; text-align: center; line-height: 1.5; }
.hidden { display: none !important; }

/* Рабочий стол */
#desktop { width: 100vw; height: 100vh; background-image: url('assets/desktop-bg.png'); background-size: cover; background-position: center; position: relative; padding: 20px; image-rendering: pixelated; image-rendering: -moz-crisp-edges; image-rendering: crisp-edges; }
#desktop-icons-left { display: flex; flex-direction: column; gap: 20px; }
#desktop-icons-right { position: absolute; bottom: 60px; right: 20px; display: flex; flex-direction: column; align-items: center; gap: 20px; }

/* Стили иконки */
.icon { width: 90px; cursor: pointer; display: flex; flex-direction: column; align-items: center; }
.icon img { width: 50px; height: 50px; display: block; margin-bottom: 5px; }
.icon p { font-size: 12px; padding: 2px 4px; text-align: center; text-shadow: 1px 1px 2px black; }
.icon.selected p { background-color: #000080; border: 1px dotted #fff; color: #fff; }

/* Стили окна */
.window { width: 480px; height: auto; min-height: 300px; background-color: #c0c0c0; border: 2px solid; border-color: #ffffff #808080 #808080 #ffffff; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); display: flex; flex-direction: column; z-index: 10; }
.title-bar { background-color: #000080; color: white; padding: 4px 8px; display: flex; justify-content: space-between; align-items: center; font-size: 14px; cursor: move; }
.close-button { width: 20px; height: 20px; background-color: #c0c0c0; border: 2px solid; border-color: #ffffff #808080 #808080 #ffffff; color: black; font-family: monospace; font-weight: bold; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.window-body { padding: 20px; color: black; font-size: 14px; line-height: 1.6; flex-grow: 1; display: flex; flex-direction: column; justify-content: center; }
.window-button { font-family: 'Press Start 2P', cursive; padding: 8px 12px; margin-top: 20px; border: 2px solid; border-color: #ffffff #808080 #808080 #ffffff; background-color: #c0c0c0; cursor: pointer; }

/* Квест 1: Таймер + Квест 3: Звуковая игра */
#quest-intro, #quest-final, #sound-final, #sound-game-container { text-align: center; }
#quest-question { margin-bottom: 20px; font-size: 13px; color: #000; }
#quest-options, #sound-quest-options { display: flex; flex-direction: column; gap: 10px; margin-bottom: 10px; }
#sound-quest-text { text-align: center; margin-bottom: 20px; color: #000; height: 40px; }
.option { font-family: 'Press Start 2P', cursive; padding: 10px; border: 2px solid; border-color: #ffffff #808080 #808080 #ffffff; background-color: #c0c0c0; cursor: pointer; text-align: left; font-size: 11px; color: #000; width: 100%; }
.option:hover { background-color: #dcdcdc; }
.option.wrong { background-color: #ff8a8a; border-color: #ff0000 #a00000 #a00000 #ff0000; }
.option.correct { background-color: #90ee90; border-color: #aaffaa #008000 #008000 #aaffaa; }
#quest-final h2, #sound-final h2 { margin-bottom: 15px; color: #000080; }
.final-wish { margin-top: 20px; font-size: 14px; color: #000; font-weight: bold; }
#listen-again-btn { font-size: 10px; padding: 5px 8px; margin-top: 10px; }

/* Квест 2: Терминал */
.terminal { background-color: #000; color: #00FF00; font-size: 14px; line-height: 1.5; padding: 10px; justify-content: flex-start; }
.terminal p { margin: 0; white-space: pre-wrap; word-break: break-all; }
.cursor { animation: blink 1s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* Стили для "Блокнота" и "Свойств" */
.notepad-body { background-color: #fff; color: #000; font-family: 'Courier New', Courier, monospace; font-size: 14px; justify-content: flex-start; white-space: pre-wrap; }
.sys-props { justify-content: flex-start; }
.sys-props p { font-size: 12px; margin-bottom: 10px; }
.sys-props strong { display: inline-block; width: 140px; }

/* Стили для видеоплеера */
.video-body { padding: 0; background-color: #000; overflow: hidden; }
.video-body iframe { width: 100%; height: 100%; }

/* Панель задач */
#taskbar { position: absolute; bottom: 0; left: 0; width: 100%; height: 40px; background-color: #c0c0c0; border-top: 2px solid #ffffff; display: flex; align-items: center; justify-content: space-between; padding: 3px; color: #000; z-index: 20; }
.start-button, .start-button:active { padding: 5px 15px; border: 2px solid; box-shadow: 1px 1px 0px #000; cursor: pointer; }
.start-button { border-color: #ffffff #808080 #808080 #ffffff; }
.start-button:active { border-color: #808080 #ffffff #ffffff #808080; }
.clock { padding: 5px 10px; border: 2px solid; border-color: #808080 #ffffff #ffffff #808080; font-size: 14px; }

/* Оверлеи для наград */
#reward-overlay, #pemza-reward-overlay, #sound-reward-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.85); display: flex; justify-content: center; align-items: center; z-index: 200; cursor: pointer; }
#reward-overlay img, #pemza-reward-overlay img, #sound-reward-overlay img { max-width: 90%; max-height: 90%; border: 4px solid #fff; box-shadow: 0 0 20px rgba(255, 255, 255, 0.5); }