* { box-sizing: border-box; }

html, body {
    margin: 0; padding: 0; width: 100vw; height: 100vh;
    background-color: #0d0d12; color: #fff;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    overflow: hidden; /* Скрываем скролл, двигаем только мышью */
    -webkit-font-smoothing: antialiased;
}

/* === НАВИГАЦИЯ ДЛЯ ПК === */
nav {
    position: fixed; top: 0; left: 0; width: 100%;
    padding: 20px; display: flex; justify-content: center; gap: 40px;
    background: rgba(13, 13, 18, 0.8); backdrop-filter: blur(10px);
    z-index: 1000; border-bottom: 1px solid rgba(255,255,255,0.05);
}
nav a {
    color: rgba(255, 255, 255, 0.6); text-decoration: none;
    text-transform: uppercase; font-weight: bold; letter-spacing: 2px;
    font-size: 0.9rem; transition: 0.3s;
}
nav a:hover, nav a.active { color: #ffffff; text-shadow: 0 0 10px #b026ff; }
nav a.active { border-bottom: 2px solid #b026ff; padding-bottom: 5px; }

/* === ИНТЕРФЕЙС И КНОПКИ === */
.header-container {
    position: fixed; top: 100px; left: 50%; transform: translateX(-50%);
    text-align: center; z-index: 100; pointer-events: none;
}
.header-container h1 {
    font-size: 3rem; margin: 0 0 15px 0; text-transform: uppercase;
    letter-spacing: 5px; text-shadow: 0 0 10px #b026ff, 0 0 20px #b026ff;
}

.neon-btn {
    background: linear-gradient(45deg, #7a10b3, #b026ff);
    border: none; border-radius: 30px; color: white;
    padding: 15px 40px; font-size: 1.2rem; font-weight: bold;
    text-transform: uppercase; cursor: pointer; pointer-events: auto;
    box-shadow: 0 0 20px rgba(176,38,255,0.5); transition: 0.3s;
}
.neon-btn:hover { box-shadow: 0 0 30px rgba(176,38,255,0.8); transform: translateY(-2px); }

/* === ПАНЕЛЬ ПОЛЬЗОВАТЕЛЯ (Уже есть арт) === */
#user-panel {
    position: fixed; bottom: 30px; left: 30px; top: auto; transform: none;
    background: rgba(21, 21, 28, 0.9); border: 1px solid #2a2a35;
    padding: 15px 30px; border-radius: 30px; display: flex; align-items: center; gap: 20px;
    z-index: 100; box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}
.user-info { display: flex; align-items: center; gap: 10px; font-weight: bold; letter-spacing: 1px; }
.status-dot { width: 12px; height: 12px; background: #00ffcc; border-radius: 50%; box-shadow: 0 0 10px #00ffcc; }
.outline-btn {
    background: transparent; border: 1px solid #b026ff; color: #fff;
    padding: 8px 20px; border-radius: 20px; cursor: pointer; transition: 0.3s; text-transform: uppercase;
}
.outline-btn:hover { background: rgba(176,38,255,0.2); }

/* === ПАНЕЛЬ ЗУМА === */
#zoom-panel {
    position: fixed; bottom: 30px; right: 30px;
    background: rgba(21, 21, 28, 0.9); border: 1px solid #2a2a35;
    padding: 10px; border-radius: 15px; display: flex; align-items: center; gap: 15px;
    z-index: 100; font-weight: bold;
}
#zoom-panel button { font-size: 1.5rem; width: 40px; height: 40px; padding: 0; }

/* === ИНТЕРФЕЙС РАЗМЕЩЕНИЯ (Drag & Drop) === */
#placement-ui {
    position: fixed; bottom: 40px; left: 50%; transform: translateX(-50%);
    background: rgba(13, 13, 18, 0.95); padding: 20px 40px; border-radius: 15px;
    border: 1px solid rgba(255,255,255,0.1); text-align: center; z-index: 200;
}
#placement-ui p { margin: 0 0 15px 0; font-size: 1.1rem; letter-spacing: 1px; color: #00ffcc; text-shadow: 0 0 5px #00ffcc; }
.placement-buttons { display: flex; gap: 15px; justify-content: center; }
.cancel-btn { background: #333 !important; box-shadow: none !important; }
.cancel-btn:hover { background: #444 !important; }
.success-btn { background: linear-gradient(45deg, #00b38f, #00ffcc) !important; color: #000 !important; box-shadow: 0 0 20px rgba(0,255,204,0.5) !important; }

/* === СТЕНА (ХОЛСТ) === */
#wall-wrapper { position: absolute; top: 0; left: 0; width: 100%; height: 100%; cursor: grab; }
#wall-wrapper:active { cursor: grabbing; }

#world-board {
    width: 1500px; height: 1500px; background-color: #15151c;
    background-image: url("data:image/svg+xml,%3Csvg width='50' height='50' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M 50 0 L 0 0 0 50' fill='none' stroke='rgba(255,255,255,0.05)' stroke-width='2'/%3E%3C/svg%3E");
    border: 4px solid #b026ff; position: absolute; transform-origin: 0 0;
}

/* === МОДАЛЬНОЕ ОКНО РИСОВАНИЯ === */
#paint-modal {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(13, 13, 18, 0.95); backdrop-filter: blur(10px);
    display: flex; justify-content: center; align-items: center; z-index: 9999;
}
.modal-content {
    background: #15151c; border: 1px solid #2a2a35; border-radius: 20px;
    padding: 30px; text-align: center; position: relative; box-shadow: 0 20px 50px rgba(0,0,0,0.8);
}
.paint-close-btn {
    position: absolute; top: 15px; right: 15px; background: transparent; border: none;
    color: white; font-size: 1.5rem; cursor: pointer; transition: 0.3s;
}
.paint-close-btn:hover { color: #ff2660; }
.canvas-container { background: #fff; padding: 0; border-radius: 10px; display: inline-block; margin: 20px 0; box-shadow: 0 0 20px rgba(255,255,255,0.1); }
#drawing-pad { cursor: crosshair; display: block; width: 400px; height: 400px; }
.tools-panel { display: flex; justify-content: center; align-items: center; gap: 15px; margin-bottom: 20px; }
.tool-btn { background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.2); color: white; padding: 10px 15px; border-radius: 10px; cursor: pointer; transition: 0.3s; }
.tool-btn:hover { background: rgba(255,255,255,0.1); }
.hidden { display: none !important; }

/* === СЕКРЕТНЫЙ РЕЖИМ АДМИНА === */
#admin-trigger {
    position: fixed; bottom: 10px; right: 15px;
    color: rgba(255,255,255,0.05); font-size: 12px;
    cursor: pointer; user-select: none; z-index: 10000;
}
#admin-glow {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    box-shadow: inset 0 0 120px rgba(176, 38, 255, 0.7), inset 0 0 30px rgba(176, 38, 255, 1);
    pointer-events: none; z-index: 9998; opacity: 0; transition: opacity 1s ease;
}
body.admin-mode #admin-glow { opacity: 1; }
#admin-panel-link {
    display: none; position: fixed; bottom: 100px; left: 30px;
    background: linear-gradient(45deg, #7a10b3, #b026ff);
    color: white; padding: 15px 30px; border-radius: 30px;
    text-transform: uppercase; font-weight: bold; text-decoration: none;
    box-shadow: 0 0 20px #b026ff; z-index: 10000; letter-spacing: 2px;
}
body.admin-mode #admin-panel-link { display: block; }

/* === НОВЫЕ СТИЛИ: УДАЛЕНИЕ И ПАГИНАЦИЯ === */

/* Красная кнопка удаления */
.danger-outline-btn {
    background: transparent; border: 1px solid #ff2660; color: #ff2660;
    padding: 8px 20px; border-radius: 20px; cursor: pointer; transition: 0.3s; text-transform: uppercase;
    box-shadow: 0 0 10px rgba(255, 38, 96, 0.2);
}
.danger-outline-btn:hover { background: rgba(255, 38, 96, 0.1); box-shadow: 0 0 15px rgba(255, 38, 96, 0.5); }

/* Панель переключения страниц */
#pagination-panel {
    position: fixed; bottom: 30px; left: 50%; transform: translateX(-50%);
    background: rgba(21, 21, 28, 0.9); border: 1px solid #2a2a35;
    padding: 10px 20px; border-radius: 30px; display: flex; align-items: center; gap: 20px;
    z-index: 100; box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}
.page-btn {
    background: transparent; border: none; color: #b026ff; font-size: 1.5rem;
    cursor: pointer; transition: 0.3s; padding: 0 10px; text-shadow: 0 0 10px rgba(176,38,255,0.5);
}
.page-btn:hover:not(:disabled) { transform: scale(1.2); color: #ffffff; }
.page-btn:disabled { color: #555; cursor: not-allowed; text-shadow: none; }
.page-info { display: flex; flex-direction: column; align-items: center; line-height: 1.2; }
#page-number { font-weight: bold; font-size: 1.1rem; text-transform: uppercase; letter-spacing: 2px; }
.page-count-hint { font-size: 0.8rem; color: rgba(255,255,255,0.5); }