/* ============================================
   СТРАНИЦА ПОИСКА
   ============================================ */

/* Сетка результатов поиска */
.search-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

/* Карточка результата поиска */
.search-result-card {
    display: flex;
    gap: 16px;
    padding: 16px;
    background: linear-gradient(135deg, rgba(28, 28, 28, 0.85) 0%, rgba(46, 46, 46, 0.85) 100%);
    border: 1.5px solid rgba(255, 140, 0, 0.15);
    border-radius: 14px;
    text-decoration: none;
    color: var(--white);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.search-result-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 140, 0, 0.08) 0%, transparent 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.search-result-card:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 140, 0, 0.4);
    box-shadow: 0 8px 28px rgba(255, 140, 0, 0.25);
}

.search-result-card:hover::before {
    opacity: 1;
}

/* Постер результата */
.search-result-poster {
    position: relative;
    flex-shrink: 0;
    width: 100px;
    height: 150px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.35);
    border: 1.5px solid rgba(255, 140, 0, 0.12);
    transition: all 0.3s ease;
}

.search-result-card:hover .search-result-poster {
    box-shadow: 0 6px 20px rgba(255, 140, 0, 0.3);
    border-color: rgba(255, 140, 0, 0.3);
    transform: scale(1.03);
}

.search-result-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.search-result-card:hover .search-result-poster img {
    transform: scale(1.08);
}

/* Бейджи рейтингов */
.search-rating-badge {
    position: absolute;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-family-graphik_lcg-medium);
    font-size: 11px;
    font-weight: 700;
    box-shadow: 
        0 2px 6px rgba(0, 0, 0, 0.4),
        0 0 0 1.5px rgba(255, 255, 255, 0.1);
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    background: rgba(0, 0, 0, 0.75);
    color: #fff;
    z-index: 3;
    backdrop-filter: blur(3px);
}

.search-movie-rating {
    top: 5px;
    right: 5px;
}

.search-user-rating {
    top: 5px;
    left: 5px;
}

.search-rating-badge.good {
    background: linear-gradient(135deg, #00C853 0%, #00E676 100%);
    color: #fff;
    border-color: rgba(0, 200, 83, 0.4);
}

.search-rating-badge.medium {
    background: linear-gradient(135deg, #FFD600 0%, #FFEA00 100%);
    color: #212529;
    border-color: rgba(255, 214, 0, 0.4);
}

.search-rating-badge.bad {
    background: linear-gradient(135deg, #D50000 0%, #FF1744 100%);
    color: #fff;
    border-color: rgba(213, 0, 0, 0.4);
}

/* Информация о результате */
.search-result-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    z-index: 1;
}

.search-result-title {
    font-family: var(--font-family-graphik_lcg-medium);
    font-size: 18px;
    font-weight: 500;
    color: var(--white);
    margin: 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.3s ease;
}

.search-result-card:hover .search-result-title {
    color: var(--main-color);
}

.search-result-year {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 400;
}

.search-result-description {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 4px;
}

/* Счетчик результатов */
.section-results-count {
    color: rgba(255, 255, 255, 0.6);
    font-size: 16px;
    font-family: var(--font-family-graphik_lcg-regular);
}

/* Адаптивность */
@media (max-width: 850px) {
    .search-results-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 16px;
    }

    .search-result-card {
        padding: 14px;
        gap: 12px;
    }

    .search-result-poster {
        width: 85px;
        height: 130px;
    }

    .search-result-title {
        font-size: 16px;
    }

    .search-result-description {
        font-size: 12px;
        -webkit-line-clamp: 2;
    }
}

@media (max-width: 600px) {
    .search-results-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .search-result-card {
        padding: 12px;
        gap: 10px;
    }

    .search-result-poster {
        width: 75px;
        height: 115px;
    }

    .search-result-title {
        font-size: 15px;
    }

    .search-result-year {
        font-size: 12px;
    }

    .search-result-description {
        font-size: 11px;
    }
}

/* Жанры в результатах поиска */
.search-result-genres {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 4px;
    font-style: italic;
}

/* Причина рекомендации */
.recommendation-reason {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 6px;
    padding: 6px 10px;
    background: rgba(255, 140, 0, 0.1);
    border: 1px solid rgba(255, 140, 0, 0.2);
    border-radius: 6px;
    font-size: 11px;
    color: var(--main-color);
    font-family: var(--font-family-graphik_lcg-medium);
}

.recommendation-reason svg {
    flex-shrink: 0;
    width: 14px;
    height: 14px;
}

.recommendation-card:hover .recommendation-reason {
    background: rgba(255, 140, 0, 0.15);
    border-color: rgba(255, 140, 0, 0.3);
}

/* Кнопка "Не интересно" */
.recommendation-not-interesting {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
}

.recommendation-not-interesting:hover {
    background: rgba(213, 0, 0, 0.8);
    border-color: rgba(255, 255, 255, 0.4);
    color: #fff;
    transform: scale(1.1);
}

.recommendation-not-interesting.active {
    background: rgba(213, 0, 0, 0.9);
    border-color: #D50000;
    color: #fff;
}

.recommendation-card {
    position: relative;
}
