/**
 * 口コミ検索機能専用CSS
 * 検索フォーム、検索結果、フィルター等のスタイル
 */

/* 検索フォームコンテナ */
.review-search-container {
    background: white;
    padding: 15px;
    border-radius: 10px;
    margin: 15px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.review-search-container h2 {
    color: #333;
    text-align: left;
    margin-bottom: 10px;
    font-size: 16px;
    font-weight: 600;
    border-bottom: none;
}

/* 検索フォーム */
#reviewSearchForm {
    margin-bottom: 10px;
}

.search-input-group {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
    margin-bottom: 10px;
}

#reviewSearchInput {
    flex: 1;
    min-width: 250px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.3s ease;
}

#reviewSearchInput:focus {
    border-color: #F568DF;
    box-shadow: 0 0 0 2px rgba(245, 104, 223, 0.2);
}

#reviewSearchBtn {
    background: #F568DF;
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 5px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#reviewSearchBtn:hover {
    background: #e55acf;
}

/* フィルター・ソート */
.search-filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-start;
    margin-bottom: 10px;
}

.search-filters select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    background: white;
    color: #333;
    font-size: 14px;
    outline: none;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.search-filters select:focus {
    border-color: #F568DF;
}

/* 人気キーワード */
.popular-keywords {
    margin-top: 10px;
    text-align: left;
}

.popular-keywords h4 {
    color: #333;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 600;
}

.keyword-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-start;
}

.popular-keyword {
    background: #f8f9fa;
    color: #333;
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
}

.popular-keyword:hover {
    background: #F568DF;
    color: white;
    border-color: #F568DF;
}

/* 検索結果 */
.search-results-header {
    padding: 0;
    margin: 5px 0;
    text-align: center;
}

.search-results-header h3 {
    color: #333;
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.search-results-header p {
    color: #666;
    margin: 0;
    font-size: 14px;
}

/* 検索結果リスト */
.search-results-list {
    margin: 10px 0;
}

.search-result-item {
    background: #f8f9fa;
    border-radius: 5px;
    padding: 15px;
    margin-bottom: 10px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.search-result-item:hover {
    background: #ffffff;
    border-color: #F568DF;
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 8px;
}

.review-title {
    color: #333;
    font-size: 16px;
    font-weight: 600;
    margin: 0;
    flex: 1;
    min-width: 200px;
}

.review-rating {
    font-size: 1.2rem;
    color: #ffc107;
}

.star-rating {
    white-space: nowrap;
}

.review-content {
    color: #555;
    line-height: 1.5;
    margin-bottom: 10px;
    font-size: 14px;
    text-align: left;
}

.review-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12px;
    color: #666;
}

.cast-name {
    font-weight: 600;
    color: #667eea;
    display: inline !important;
}

.cast-name-link {
    text-decoration: none;
    color: #667eea;
    font-weight: 600;
    transition: color 0.3s ease;
    display: inline !important;
}

.cast-name-link:hover {
    color: #4c63d2;
    text-decoration: underline;
}

.cast-name-text {
    color: #999;
    font-weight: 600;
    display: inline !important;
}

.cast-link {
    text-decoration: none;
    transition: color 0.3s ease;
}

.cast-link:hover {
    color: #F568DF;
    text-decoration: underline;
}

.review-date {
    color: #999;
}


/* 検索ハイライト */
.search-highlight {
    background: #fff9c4;
    color: #333;
    padding: 2px 4px;
    border-radius: 3px;
    font-weight: 600;
    box-shadow: 0 1px 2px rgba(255, 249, 196, 0.4);
}

/* ページネーション */
.pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin: 15px 0;
    flex-wrap: wrap;
}

.pagination-btn {
    background: white;
    border: 1px solid #dee2e6;
    color: #333;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    min-width: 40px;
}

.pagination-btn:hover {
    background: #f8f9fa;
    border-color: #667eea;
    color: #667eea;
}

.pagination-btn.active {
    background: #667eea;
    border-color: #667eea;
    color: white;
}

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

/* ローディング・エラー・空結果 */
.loading, .error-message, .no-results {
    text-align: center;
    padding: 40px 20px;
    background: white;
    border-radius: 12px;
    margin: 20px 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.loading {
    color: #667eea;
    font-size: 1.1rem;
}

.error-message {
    color: #dc3545;
    border-left: 4px solid #dc3545;
}

.no-results {
    color: #6c757d;
    border-left: 4px solid #6c757d;
}

.error-message h3, .no-results h3 {
    margin-bottom: 10px;
    font-size: 1.3rem;
}

/* 検索結果内のno-results-item */
.no-results-item {
    background: #f8f9fa;
    border-radius: 5px;
    padding: 20px;
    margin: 10px 0;
    border: 1px solid #e9ecef;
    text-align: center;
    color: #666;
    font-size: 14px;
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
    .review-search-container {
        padding: 20px;
        margin: 10px 0;
    }
    
    .review-search-container h2 {
        font-size: 1.5rem;
    }
    
    .search-input-group {
        flex-direction: column;
    }
    
    #reviewSearchInput {
        min-width: 100%;
    }
    
    .search-filters {
        flex-direction: column;
        align-items: center;
    }
    
    .search-filters select {
        width: 100%;
        max-width: 200px;
    }
    
    .review-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .review-meta {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .pagination {
        gap: 3px;
    }
    
    .pagination-btn {
        padding: 6px 10px;
        font-size: 12px;
        min-width: 35px;
    }
}

@media (max-width: 480px) {
    .review-search-container {
        padding: 15px;
    }
    
    .search-result-item {
        padding: 15px;
    }
    
    .review-title {
        font-size: 1.1rem;
    }
    
    .review-content {
        font-size: 14px;
    }
}
