/* Основные стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    overflow: hidden;
    background: black;
    font-family: Arial, sans-serif;
}

#gameContainer {
    position: relative;
    width: 100vw;
    height: 100vh;
}

#gameCanvas {
    display: block;
    width: 100%;
    height: 100%;
}

/* Стили для десктопного меню */
.desktop-only {
    display: block;
}

.mobile-only {
    display: none;
}

/* Стили для кнопок меню */
.menu-btn {
    background: linear-gradient(to bottom, #4a4a4a, #2a2a2a);
    color: white;
    border: 2px solid gold;
    border-radius: 5px;
    padding: 12px 30px;
    margin: 10px;
    font-size: 1.2em;
    cursor: pointer;
    width: 200px;
    transition: all 0.3s;
}

.menu-btn:hover {
    background: linear-gradient(to bottom, #5a5a5a, #3a3a3a);
    transform: scale(1.05);
}

.menu-btn:active {
    transform: scale(0.95);
}

.menu-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Стили для экрана загрузки */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    color: white;
}

.progress-container {
    width: 80%;
    max-width: 500px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 3px;
    margin: 20px 0;
}

.progress-bar {
    height: 20px;
    background: linear-gradient(to right, #4CAF50, #8BC34A);
    border-radius: 8px;
    width: 0%;
    transition: width 0.3s ease;
}

.loading-text {
    margin-top: 10px;
    color: gold;
    font-size: 1.2em;
}

.loading-details {
    color: #aaa;
    font-size: 0.9em;
    margin-top: 5px;
}

/* Стили для экрана загрузки уровня */
.level-loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    color: white;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.level-loading-screen.visible {
    opacity: 1;
}

.level-loading-text {
    font-size: 24px;
    color: gold;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.level-loading-screen.visible .level-loading-text {
    opacity: 1;
    transform: translateY(0);
}

.level-progress-container {
    width: 80%;
    max-width: 500px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 3px;
    margin: 10px 0;
    overflow: hidden;
    position: relative;
}

.level-progress-bar {
    height: 20px;
    background: linear-gradient(90deg, #4CAF50, #8BC34A, #4CAF50);
    background-size: 200% 100%;
    border-radius: 8px;
    width: 0%;
    transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
    animation: gradientMove 2s linear infinite;
}

@keyframes gradientMove {
    0% {
        background-position: 0% 50%;
    }
    100% {
        background-position: 200% 50%;
    }
}

.level-loading-details {
    color: #aaa;
    font-size: 16px;
    margin-top: 10px;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.level-loading-screen.visible .level-loading-details {
    opacity: 1;
    transform: translateY(0);
}

/* Стили для настроек */
#settings-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 1001;
    color: white;
}

#settings-menu h1 {
    color: gold;
    margin-bottom: 30px;
}

.settings-control {
    margin: 20px;
    width: 300px;
}

.settings-control label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.settings-control input[type="checkbox"] {
    margin-right: 10px;
}

.settings-control input[type="range"] {
    width: 100%;
    margin-top: 10px;
}

/* Кнопка меню для десктопа */
#desktopMenuBtn {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid gold;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    font-weight: bold;
    z-index: 1000;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
    transition: all 0.3s;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

#desktopMenuBtn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

#desktopMenuBtn:active {
    background: rgba(255, 255, 255, 0.4);
    transform: scale(0.95);
}

/* Специальные стили для кнопки "Назад в игру" на десктопе */
#back-to-game-btn {
    background: linear-gradient(to bottom, #666, #444) !important;
    border-color: #888 !important;
}

#back-to-game-btn:hover {
    background: linear-gradient(to bottom, #777, #555) !important;
}

#back-to-game-btn:active {
    background: linear-gradient(to bottom, #555, #333) !important;
} 