/* ======================
   БАЗОВЫЕ СТИЛИ 
   ====================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

#map {
    height: 100vh;
    width: 100vw;
}

.leaflet-control-attribution {
    display: none !important;
}

/* ======================
   СТИЛИ ДЛЯ КАРТЫ И ОБЪЕКТОВ
   ====================== */
.leaflet-interactive {
    transition: all 0.2s ease;
}

.leaflet-interactive:hover {
    stroke-width: 4px !important;
}

.leaflet-interactive:focus {
    outline: none !important;
}

/* Стили для подсказок */
.river-tooltip,
.lake-tooltip {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 6px;
    padding: 2px 6px;
    font-size: 12px;
    color: #333;
    white-space: nowrap;
}

.river-tooltip {
    border: 5px solid #1E90FF;
}

.lake-tooltip {
    border: 5px solid #0d6efd;
}

/* ======================
   СТИЛИ ПОПАПОВ
   ====================== */
.leaflet-popup-content-wrapper {
    padding-bottom: 10px !important;
    max-width: 600px !important;
    width: auto !important;
    min-width: 400px !important;
    border-radius: 10px !important;
    box-shadow: 0 6px 20px rgba(0,0,0,0.12) !important;
}

.leaflet-popup-content {
    width: auto !important;
    max-width: 580px !important;
    margin: 10px 15px !important;
}

/* Список рыб */
.fish-list {
    max-height: 350px;
    overflow-y: auto;
    padding-right: 5px;
    margin-right: -5px;
}

.fish-item {
    margin-bottom: 10px;
    padding: 10px;
    background: #f0f8ff;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.fish-item:hover {
    background: #d0e8ff;
    transform: translateX(3px);
}

.fish-item:active {
    transform: scale(0.97) translateX(3px);
    background: #b0d8ff;
}

.fish-item strong {
    display: block;
    margin-bottom: 5px;
    color: #1E90FF;
    font-size: 14px;
}

.fish-short-desc {
    font-size: 13px;
    line-height: 1.4;
    color: #666;
}

/* Детальная информация о рыбе */
.fish-details {
    max-width: 700px;
    max-height: 500px;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 10px;
    display: flex;
    flex-direction: column;
}

.fish-details h3 {
    color: #1E90FF;
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
    padding-bottom: 5px;
}

.fish-details section {
    margin-bottom: 15px;
    word-break: break-word;
}

.fish-details h4 {
    color: #1E90FF;
    margin: 10px 0 5px 0;
    font-size: 14px;
}

.fish-details p {
    margin: 5px 0;
    font-size: 13px;
    line-height: 1.4;
}

.life-cycle p {
    margin-left: 10px;
}

/* Кнопка "Назад" */
.popup-footer {
    margin-top: auto;
    padding-top: 15px;
    border-top: 1px solid #eee;
    text-align: center;
}

.back-button {
    background: #1E90FF;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
    width: 100%;
    max-width: 200px;
}

.back-button:hover {
    background: #0d6efd;
    transform: translateY(-2px);
}

.back-button:active {
    transform: scale(0.98);
}

/* ======================
   СТИЛИ ДЛЯ 3D МОДЕЛИ
   ====================== */
.model-container {
    padding: 10px;
    margin: 15px -10px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 8px;
    border-left: 3px solid #1E90FF;
}

.sketchfab-embed-wrapper {
    margin: 15px 0;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.sketchfab-embed-wrapper iframe {
    width: 100% !important;
    height: 250px !important;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin: 0 auto;
    display: block;
}

.model-title {
    text-align: center;
    color: #1E90FF;
    font-size: 14px;
    margin-bottom: 8px;
    font-weight: 600;
}

/* ======================
   СТИЛИ ДЛЯ РЕЧНЫХ ПОРОГОВ
   ====================== */
.adaptive-rapids-marker {
    transition: all 0.3s ease-in-out;
    animation: gentlePulse 4s infinite;
}

.rapids-tooltip {
    background: rgba(139, 69, 19, 0.9);
    border: 2px solid #8B4513;
    border-radius: 8px;
    color: white;
    font-weight: bold;
    padding: 4px 8px;
    font-size: 12px;
}

.rapids-popup h3 {
    color: #8B4513;
    margin-bottom: 10px;
}

.rapids-popup p {
    margin: 5px 0;
    font-size: 13px;
}

/* ======================
   КАСТОМНЫЙ СКРОЛЛБАР
   ====================== */
.fish-list::-webkit-scrollbar,
.fish-details::-webkit-scrollbar {
    width: 6px;
}

.fish-list::-webkit-scrollbar-track,
.fish-details::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.fish-list::-webkit-scrollbar-thumb,
.fish-details::-webkit-scrollbar-thumb {
    background: #1E90FF;
    border-radius: 3px;
}

.fish-list::-webkit-scrollbar-thumb:hover,
.fish-details::-webkit-scrollbar-thumb:hover {
    background: #0d6efd;
}

/* ======================
   ПОДСКАЗКА УПРАВЛЕНИЯ
   ====================== */
.controls-hint {
    margin-bottom: 20px;
    margin-left: 10px;
}

.controls-hint div {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(5px);
    border: 2px solid #3388ff !important;
    color: #333;
    font-size: 11px !important;
    line-height: 1.3 !important;
    padding: 8px !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15) !important;
    transition: all 0.3s ease;
}

.controls-hint:hover div {
    background: rgba(255, 255, 255, 0.98) !important;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.2) !important;
}

/* ======================
   СКРЫТИЕ СТАНДАРТНЫХ МАРКЕРОВ
   ====================== */
.leaflet-marker-icon[src*="marker-icon.png"],
.leaflet-marker-shadow {
    display: none !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
}
