/* Search Page Styles */
.search-page {
    padding: 60px 0;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    min-height: calc(100vh - 160px);
}
.search-form {
    flex-direction: row;
}

.search-header {
    text-align: center;
    margin-bottom: 40px;
}

.search-header h2 {
    font-size: 2.8rem;
    margin-bottom: 15px;
    color: #fff;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.6);
    position: relative;
    padding-bottom: 20px;
}

.search-header h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background: linear-gradient(90deg, #ff6b6b, #8a2be2);
    border-radius: 2px;
}

.search-subtitle {
    font-size: 1.2rem;
    color: #ddd;
    max-width: 600px;
    margin: 0 auto;
}

.search-form-container {
    max-width: 800px;
    margin: 0 auto 40px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    backdrop-filter: blur(5px);
}

.search-form {
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    display: flex;
    transition: all 0.3s ease;
    height: 70px;
}

.search-form:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}

.search-form::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff6b6b, #8a2be2);
    z-index: 2;
}

.search-input-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
}

#search-page-input {
    width: 100%;
    height: 70px;
    padding: 0 25px;
    font-size: 1.1rem;
    border: none;
    background: transparent;
    color: #fff;
    transition: all 0.3s ease;
    z-index: 1;
    position: relative;
}

#search-page-input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.05);
}

#search-page-input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.search-button-wrapper {
    display: flex;
    align-items: center;
}

#search-page-btn {
    height: 100%;
    height: 70px;
    padding: 0 35px;
    background: transparent;
    color: white;
    border: none;
    cursor: pointer;
    font-weight: bold;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
}

#search-page-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #ff6b6b, #8a2be2);
    z-index: -1;
    transition: all 0.3s ease;
}

#search-page-btn:hover::before {
    opacity: 0.9;
}

#search-page-btn:active::before {
    transform: scale(0.95);
}

#search-page-btn span {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
}

#search-page-btn span::before {
    content: '🔍';
    margin-right: 8px;
    font-size: 1.2rem;
}

.search-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 30px 0;
    padding: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.search-summary h3 {
    color: #fff;
    font-size: 2rem;
    margin-bottom: 10px;
    text-align: left;
}

.search-summary h3::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #ff6b6b, #8a2be2);
    border-radius: 2px;
}

.search-details {
    color: #ddd;
    font-size: 1.1rem;
    margin: 0;
}

.search-details span {
    font-weight: bold;
    color: #ff6b6b;
}

.search-content {
    display: flex;
    gap: 30px;
    margin-top: 30px;
}

.search-results {
    flex: 3;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.games-container {
    flex: 3;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.search-filters {
    flex: 1;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    align-self: flex-start;
}

.search-filters h4 {
    color: #fff;
    font-size: 1.3rem;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.filter-group {
    margin-bottom: 20px;
}

.filter-group h5 {
    color: #ddd;
    font-size: 1.1rem;
    margin-bottom: 10px;
}

.filter-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.filter-btn {
    padding: 8px 15px;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.filter-btn:hover, .filter-btn.active {
    background: linear-gradient(135deg, #ff6b6b, #8a2be2);
}

.search-results .no-results {
    text-align: center;
    color: #ddd;
    font-size: 1.2rem;
    padding: 40px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: absolute;
    left: 0;
    right: 0;
    width: 350px;
    margin: auto;

}

.load-more-container {
    text-align: center;
    margin: 40px auto 0;
    padding: 20px;
}

.load-more-btn {
    padding: 15px 40px;
    font-size: 1.1rem;
    background: linear-gradient(135deg, #ff6b6b, #8a2be2);
    color: white;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    letter-spacing: 1px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.load-more-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(138, 43, 226, 0.4);
}

.load-more-btn:active {
    transform: translateY(-1px);
}

.load-more-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
}

.load-more-btn:hover::before {
    left: 100%;
}

/* Search Results Game Cards */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 20px;
}

.game-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    backdrop-filter: blur(10px);
}

/* 为搜索结果游戏卡片添加渐变色边框效果 */
.game-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(-225deg, #A445B2 0%, #D41872 52%, #FF0066 100%);
    z-index: -1;
    border-radius: 15px;
    padding: 2px;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: destination-out;
    mask-composite: exclude;
}

.game-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
}

.game-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #ff6b6b, #8a2be2);
}

.game-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.game-card-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.game-card h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
    color: #333;
}

.game-card p {
    font-size: 0.95rem;
    color: #666;
    margin-bottom: 20px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.game-card .play-btn {
    display: block;
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, #ff6b6b, #8a2be2);
    color: white;
    text-align: center;
    text-decoration: none;
    border-radius: 30px;
    font-weight: bold;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.game-card .play-btn:hover {
    background: linear-gradient(135deg, #ff5252, #7a1ad2);
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(138, 43, 226, 0.4);
}

/* Animation for search results */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(138, 43, 226, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(138, 43, 226, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(138, 43, 226, 0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.search-results .game-card {
    animation: fadeInUp 0.6s ease forwards;
}

.search-results .game-card:nth-child(1) { animation-delay: 0.1s; }
.search-results .game-card:nth-child(2) { animation-delay: 0.2s; }
.search-results .game-card:nth-child(3) { animation-delay: 0.3s; }
.search-results .game-card:nth-child(4) { animation-delay: 0.4s; }
.search-results .game-card:nth-child(5) { animation-delay: 0.5s; }
.search-results .game-card:nth-child(6) { animation-delay: 0.6s; }
.search-results .game-card:nth-child(7) { animation-delay: 0.7s; }
.search-results .game-card:nth-child(8) { animation-delay: 0.8s; }
.search-results .game-card:nth-child(9) { animation-delay: 0.9s; }
.search-results .game-card:nth-child(10) { animation-delay: 1.0s; }
.search-results .game-card:nth-child(11) { animation-delay: 1.1s; }
.search-results .game-card:nth-child(12) { animation-delay: 1.2s; }

.search-filters {
    animation: slideInLeft 0.5s ease forwards;
}

/* Search form focus animation */
#search-page-input:focus {
    animation: pulse 2s infinite;
}

/* Responsive Design */
@media (max-width: 768px) {
    .search-page {
        padding: 40px 0;
    }
    
    .search-header h2 {
        font-size: 2.2rem;
        margin-bottom: 15px;
    }
    
    .search-subtitle {
        font-size: 1rem;
    }
    
    .search-form-container {
        padding: 15px;
    }
    
    .search-form {
        max-width: 90%;
        border-radius: 30px;
        height: 50px;
        
    }
    
    .search-input-wrapper {
        width: 100%;
    }
    
    #search-page-input {
        padding: 18px 20px;
        height: 50px;
        font-size: 1rem;
    }
    
    .search-button-wrapper {
        width: 30%;
    }
    
    #search-page-btn {
        padding: 15px 15px;
        font-size: 1rem;
        width: 100%;
        justify-content: center;
    }
    
    .search-content {
        flex-direction: column;
        margin-bottom: 100px;
    }
    
    .search-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .search-filters {
        width: 100%;
    }
    
    .games-container {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 20px;
    }
    
    .game-card img {
        height: 150px;
    }
    
    /* 优化移动端搜索结果游戏卡片 */
    .game-card {
        border-radius: 10px;
    }
    
    .game-card::after {
        border-radius: 10px;
    }
    
    .game-card-content {
        padding: 15px;
    }
    
    .game-card h3 {
        font-size: 1.1rem;
    }
    
    .game-card p {
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .search-page {
        padding: 30px 0;
    }
    
    .search-header h2 {
        font-size: 1.8rem;
        margin-bottom: 15px;
    }
    
    .search-subtitle {
        font-size: 0.9rem;
    }
    
    .search-form-container {
        padding: 10px;
    }
    
    .search-form {
        max-width: 95%;
        border-radius: 25px;
        height: 45px;
    }
    
    #search-page-input {
        padding: 15px;
        height: 45px;
        font-size: 0.95rem;
    }
    
    #search-page-btn {
        padding: 15px 20px;
        font-size: 0.95rem;
    }
    
    .search-summary h3 {
        font-size: 1.4rem;
    }
    
    .search-details {
        font-size: 0.9rem;
    }
    
    .load-more-btn {
        padding: 12px 30px;
        font-size: 1rem;
    }
    
    .games-container {
        grid-template-columns: 1fr;
    }
    
    .game-card img {
        height: 180px;
    }
    
    /* 进一步优化超小屏幕搜索结果游戏卡片 */
    .game-card {
        border-radius: 8px;
    }
    
    .game-card::after {
        border-radius: 8px;
    }
    
    .game-card-content {
        padding: 12px;
    }
    
    .game-card h3 {
        font-size: 1rem;
    }
    
    .game-card p {
        font-size: 0.8rem;
    }
    
    .game-card .play-btn {
        padding: 10px;
        font-size: 0.9rem;
    }
}