/
itfed
/
boss-timer
Обзор
Документация
Войти
/
itfed
/
boss-timer
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
CI/CD
Аналитика
Безопасность
main
static/style.css
778 строк
17 KB
Константин Федунов
Сделал глобальную историю сворачиваемой по умолчанию
22 янв 2026, 18:40
22 янв 2026, 18:40
d71f7b3
Код
Авторство
О чём код?
* { margin: 0; padding: 0; box-sizing: border-box; } body { font-family: 'Roboto', sans-serif; background: linear-gradient(135deg, #0f2027 0%, #203a43 50%, #2c5364 100%); color: #fff; min-height: 100vh; padding: 20px; line-height: 1.6; } .container { max-width: 1200px; margin: 0 auto; background-color: rgba(255, 255, 255, 0.05); border-radius: 20px; padding: 30px; box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5); backdrop-filter: blur(10px); border: 1px solid rgba(255, 255, 255, 0.1); } /* Шапка */ header { text-align: center; margin-bottom: 20px; padding-bottom: 15px; border-bottom: 1px solid rgba(255, 255, 255, 0.1); } h1 { font-size: 2.5rem; margin-bottom: 15px; background: linear-gradient(45deg, #00c6ff, #0072ff); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; display: flex; align-items: center; justify-content: center; gap: 10px; } .server-time { background: rgba(0, 114, 255, 0.15); padding: 8px 15px; border-radius: 8px; display: inline-block; font-family: 'Courier New', monospace; font-size: 1rem; border: 1px solid rgba(0, 114, 255, 0.2); } /* Панель управления */ .controls { display: flex; justify-content: center; gap: 15px; margin-bottom: 25px; padding: 15px; background: rgba(255, 255, 255, 0.03); border-radius: 12px; border: 1px solid rgba(255, 255, 255, 0.08); } button { padding: 12px 25px; border: none; border-radius: 10px; font-size: 1rem; font-weight: bold; cursor: pointer; transition: all 0.3s ease; display: flex; align-items: center; gap: 10px; } .refresh-btn { background: linear-gradient(45deg, #00c6ff, #0072ff); color: white; } .refresh-btn:hover { transform: translateY(-2px); box-shadow: 0 5px 15px rgba(0, 198, 255, 0.4); } .reset-btn { background: rgba(255, 65, 108, 0.2); color: #ff416c; border: 1px solid rgba(255, 65, 108, 0.3); } .reset-btn:hover { background: rgba(255, 65, 108, 0.3); } .undo-btn { background: rgba(255, 193, 7, 0.2); color: #FFC107; border: 1px solid rgba(255, 193, 7, 0.3); } .undo-btn:hover { background: rgba(255, 193, 7, 0.3); transform: translateY(-2px); box-shadow: 0 5px 15px rgba(255, 193, 7, 0.4); } .clear-history-btn { background: rgba(156, 39, 176, 0.2); color: #9c27b0; border: 1px solid rgba(156, 39, 176, 0.3); } .clear-history-btn:hover { background: rgba(156, 39, 176, 0.3); transform: translateY(-2px); box-shadow: 0 5px 15px rgba(156, 39, 176, 0.4); } /* Контейнер боссов - вертикальный список */ .bosses-grid { display: flex; flex-direction: column; gap: 10px; margin-bottom: 30px; width: 100%; } /* Карточка босса - структура из 2 строк */ .boss-card { background: linear-gradient(145deg, #2D2D3A, #1F1F28); border-radius: 12px; padding: 15px; border: 1px solid #444455; transition: all 0.3s ease; position: relative; overflow: hidden; margin-bottom: 10px; /* Вертикальная структура из 2 строк */ display: flex; flex-direction: column; gap: 15px; width: 100%; box-sizing: border-box; } .boss-card:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3); border-color: #555566; } /* Первая строка - центрирование ключевых элементов */ .first-row { display: flex; align-items: baseline; justify-content: space-between; width: 100%; gap: 20px; font-family: 'Roboto', sans-serif; font-size: 1rem; } /* Имя босса - прижато к левой стороне */ .boss-header { display: flex; align-items: center; gap: 10px; min-width: 200px; flex-shrink: 0; } /* Статус - центрирован по вертикали */ .boss-status { display: flex; align-items: center; justify-content: center; min-width: 140px; flex-shrink: 0; align-self: center; /* Центрируем по вертикали */ } .boss-status .status { font-size: 1rem; font-weight: 600; padding: 6px 12px; border-radius: 6px; text-align: center; white-space: nowrap; display: block; width: 100%; box-sizing: border-box; } /* Таймер - центрирован по вертикали */ .timer-section { display: flex; flex-direction: column; align-items: center; padding: 10px 15px; background: rgba(0, 0, 0, 0.3); border-radius: 10px; border: 1px solid rgba(255, 255, 255, 0.15); min-width: 140px; flex-shrink: 0; align-self: center; /* Центрируем по вертикали */ } .timer { font-family: 'Courier New', monospace; font-size: 1.4rem; font-weight: bold; text-align: center; color: #00FFFF; letter-spacing: 1px; margin-bottom: 0; } .timer-label { color: #888899; font-size: 0.75rem; text-align: center; margin-top: 2px; } /* Информация - базовое выравнивание */ .boss-kill-info { display: flex; flex-direction: column; gap: 5px; min-width: 150px; flex-shrink: 0; align-self: center; /* Только вертикальное центрирование */ } .info-row { display: flex; align-items: center; gap: 6px; font-size: 0.85rem; white-space: nowrap; /* Убрал justify-content: center */ } .info-row .label { color: #888899; font-weight: 500; } .info-row .value, .info-row .status { color: #CCCCCC; font-weight: 400; } /* Кнопка - прижата к правой стороне (оригинальное позиционирование) */ .boss-actions { display: flex; flex-direction: row; /* Располагаем кнопки горизонтально */ min-width: 160px; /* Увеличенная ширина для двух элементов */ flex-shrink: 0; justify-content: flex-end; /* Прижимаем к правому краю */ align-self: center; /* Центрируем по вертикали */ gap: 8px; /* Отступ между кнопкой и иконкой */ } .kill-btn { background: linear-gradient(145deg, #ff416c, #ff4b2b); /* Красный градиент */ color: white; border: none; padding: 12px 20px; border-radius: 6px; cursor: pointer; font-size: 1rem; font-weight: 500; transition: all 0.2s ease; white-space: nowrap; width: 100%; box-shadow: 0 2px 8px rgba(255, 65, 108, 0.3); /* margin-bottom удален - теперь используем gap в .boss-actions */ } .undo-icon-btn { background: rgba(255, 193, 7, 0.2); /* Желтый фон */ color: #FFC107; border: 1px solid rgba(255, 193, 7, 0.3); padding: 8px 12px; /* Компактные отступы */ border-radius: 6px; cursor: pointer; font-size: 1.2rem; /* Размер иконки */ transition: all 0.2s ease; display: flex; align-items: center; justify-content: center; min-width: 40px; /* Фиксированная ширина */ height: 40px; /* Фиксированная высота */ } .kill-btn:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(255, 65, 108, 0.5); } .undo-icon-btn:hover:not(:disabled) { background: rgba(255, 193, 7, 0.3); transform: translateY(-2px); box-shadow: 0 5px 15px rgba(255, 193, 7, 0.4); /* hover эффект как у оригинальной кнопки Отменить */ } .kill-btn:disabled { background: #616161; cursor: not-allowed; transform: none; box-shadow: none; } .undo-icon-btn:disabled { background: #616161; color: #999999; cursor: not-allowed; transform: none; box-shadow: none; border: 1px solid #616161; } /* Кнопка истории в первой строке */ .boss-history-trigger { display: flex; align-items: center; gap: 8px; min-width: 120px; flex-shrink: 0; align-self: center; cursor: pointer; padding: 8px 12px; border-radius: 6px; transition: all 0.2s ease; } .boss-history-trigger:hover { background: rgba(255, 255, 255, 0.1); } .history-text { color: #888899; font-size: 0.9rem; font-weight: 500; } .toggle-icon { color: #00FFFF; font-size: 0.8rem; transition: transform 0.3s ease; } /* Стили для заголовка глобальной истории */ .history-header { display: flex; justify-content: space-between; align-items: center; cursor: pointer; padding: 10px 15px; border-radius: 8px; transition: background-color 0.2s ease; user-select: none; } .history-header:hover { background-color: rgba(255, 255, 255, 0.05); } .history-header h3 { margin: 0; font-size: 1.2rem; display: flex; align-items: center; gap: 10px; } #global-history-toggle { font-size: 1.2rem; transition: transform 0.3s ease; } .boss-history-trigger.expanded .toggle-icon { transform: rotate(180deg); } .history-expanded #global-history-toggle { transform: rotate(180deg); } /* Адаптивность для мобильных */ @media (max-width: 768px) { .boss-card { padding: 15px; } .first-row { flex-direction: column; gap: 15px; } .boss-header { min-width: auto; } .boss-actions { min-width: auto; justify-content: center; } } /* Статусы боссов - оригинальные стили из ветки main */ .status.alive { background: rgba(76, 175, 80, 0.2); color: #4caf50; border: 1px solid rgba(76, 175, 80, 0.3); } .status.respawning { background: rgba(0, 198, 255, 0.2); color: #00c6ff; border: 1px solid rgba(0, 198, 255, 0.3); } .status.respawning-now { background: linear-gradient(45deg, rgba(255, 193, 7, 0.3), rgba(255, 152, 0, 0.3)); color: #FFC107; border: 2px solid #FFC107; font-weight: bold; animation: pulse-glow 2s infinite; } .status.ready { background: rgba(255, 65, 108, 0.2); color: #ff416c; border: 1px solid rgba(255, 65, 108, 0.3); } /* Анимация для активного статуса */ @keyframes pulse-glow { 0% { box-shadow: 0 0 5px rgba(255, 193, 7, 0.5); } 50% { box-shadow: 0 0 20px rgba(255, 193, 7, 0.8); } 100% { box-shadow: 0 0 5px rgba(255, 193, 7, 0.5); } } /* Анимации */ @keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } } @keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } } @keyframes slideOut { from { transform: translateX(0); opacity: 1; } to { transform: translateX(100%); opacity: 0; } } .boss-card { animation: fadeIn 0.5s ease-out; } .loading { text-align: center; padding: 50px; grid-column: 1 / -1; color: #aaa; font-size: 1.2rem; } .fa-spin { margin-right: 10px; } /* Уведомления */ .notification { position: fixed; top: 20px; right: 20px; background: linear-gradient(45deg, #00c6ff, #0072ff); color: white; padding: 15px 25px; border-radius: 10px; box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3); z-index: 1000; animation: slideIn 0.3s ease-out; } /* Скроллбар */ ::-webkit-scrollbar { width: 8px; } ::-webkit-scrollbar-track { background: rgba(255, 255, 255, 0.05); border-radius: 4px; } ::-webkit-scrollbar-thumb { background: rgba(0, 198, 255, 0.3); border-radius: 4px; } ::-webkit-scrollbar-thumb:hover { background: rgba(0, 198, 255, 0.5); } /* Адаптивность */ @media (max-width: 768px) { .container { padding: 15px; } h1 { font-size: 2rem; flex-direction: column; gap: 10px; } .controls { flex-direction: column; gap: 15px; align-items: stretch; } .bosses-grid { grid-template-columns: 1fr; } .timer { font-size: 1.8rem; padding: 10px; } .boss-actions { flex-direction: column; } button { justify-content: center; } } @media (max-width: 480px) { .boss-header { flex-direction: column; align-items: flex-start; gap: 10px; } .boss-name { flex-direction: column; align-items: flex-start; gap: 10px; } .boss-icon { font-size: 2rem; } .info-row { flex-direction: column; align-items: flex-start; gap: 5px; } .timer { font-size: 1.5rem; } } /* Стили для времени убийства */ .kill-time { color: #00FFFF; font-weight: 500; cursor: pointer; transition: all 0.2s ease; padding: 2px 4px; border-radius: 3px; } .kill-time:hover { background: rgba(0, 255, 255, 0.1); } .kill-time:active { background: rgba(0, 255, 255, 0.2); } /* Компактные таймеры Море и Глубина */ .compact-timers { display: flex; gap: 20px; margin: 20px 0; justify-content: center; flex-wrap: wrap; } .compact-timer { display: flex; align-items: center; gap: 10px; background: rgba(255, 255, 255, 0.05); padding: 12px 20px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, 0.1); min-width: 200px; } .timer-label { color: #888899; font-weight: 500; font-size: 1rem; } .timer-value { font-family: 'Courier New', monospace; font-size: 1.3rem; font-weight: bold; color: #00FFFF; letter-spacing: 1px; } .play-btn { background: transparent; color: #00FFFF; border: 1px solid rgba(0, 255, 255, 0.3); border-radius: 6px; width: 30px; height: 30px; cursor: pointer; font-size: 1rem; transition: all 0.2s ease; display: flex; align-items: center; justify-content: center; margin-right: 5px; } .play-btn:hover { background: rgba(0, 255, 255, 0.1); border-color: rgba(0, 255, 255, 0.5); transform: scale(1.1); } /* .stop-btn стили удалены - кнопка больше не используется */ /* Убираю цветные подсветки .sea-timer { border-left: 3px solid #00c6ff; } .depth-timer { border-left: 3px solid #FFC107; } */ /* Адаптивность для мобильных */ @media (max-width: 768px) { .compact-timers { flex-direction: column; align-items: center; gap: 10px; } .compact-timer { min-width: 180px; padding: 10px 15px; } .timer-value { font-size: 1.1rem; } } /* Скрытые админ-кнопки внизу страницы */ .admin-controls { display: flex; justify-content: center; gap: 20px; margin-top: 40px; padding: 20px; background: rgba(255, 255, 255, 0.03); border-radius: 10px; border: 1px dashed rgba(255, 255, 255, 0.1); } .admin-controls button { opacity: 0.6; transition: all 0.3s ease; } .admin-controls button:hover { opacity: 1; transform: scale(1.05); } /* Поле поиска боссов */ .boss-search-container { max-width: 500px; margin: 20px auto; position: relative; } .boss-search-input { width: 100%; padding: 12px 40px 12px 16px; background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.15); border-radius: 8px; color: #ffffff; font-size: 1rem; transition: all 0.3s ease; } .boss-search-input:focus { outline: none; border-color: #00FFFF; box-shadow: 0 0 0 2px rgba(0, 255, 255, 0.2); background: rgba(255, 255, 255, 0.12); } .boss-search-input::placeholder { color: #888899; } .search-clear-btn { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); background: transparent; border: none; color: #888899; font-size: 1.2rem; cursor: pointer; width: 28px; height: 28px; display: flex; align-items: center; justify-content: center; border-radius: 50%; transition: all 0.2s ease; } .search-clear-btn:hover { background: rgba(255, 255, 255, 0.1); color: #ffffff; } /* Стили для SVG иконок в кнопках */ .undo-icon-btn svg { width: 28px; height: 28px; display: block; }