/* 搜索页 高保真样式 */
/* 页面特定变量已移至 base.css */

/* ============================================
   Header Styles
   ============================================ */

body {
    margin: 0 auto;    
    max-width: 500px;
}
.search-header {
    display: flex;
    align-items: center;
    padding: 0.83rem 1.38rem 0.83rem 1.04rem;
    gap: 1.04rem;
    height: 4.15rem;
}

@media screen and (orientation: landscape) {
    .main-container {
        padding: 0;
    }
}

.search-header .back-button {
    position: static !important;
    top: auto !important;
    transform: none !important;
    left: auto !important;
    width: 2.08rem;
    height: 2.08rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
}

.back-button img {
    width: 2.08rem;
    height: 2.08rem;
}

.search-input-container {
    flex-grow: 1;
    display: flex;
    align-items: center;
    border: 0.083rem solid var(--accent-color-orange);
    border-radius: 1.55rem;
    padding: 0 1.55rem;
    height: 3.11rem;
}

.search-input {
    border: none;
    outline: none;
    background: transparent;
    width: 100%;
    font-family: inherit;
    font-size: 1.21rem;
    color: var(--text-color-light);
}

.search-input::placeholder {
    color: var(--text-color-light);
}

.search-action {
    font-size: 1.38rem;
    font-weight: 600;
    color: var(--accent-color-light);
    flex-shrink: 0;
}

/* ============================================
   Hot Games Section Styles
   ============================================ */
.hot-games-section {
    padding: 0 1.04rem;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.hot-games-title {
    width: 100%;
    height: auto;
}

.hot-games-list {
    list-style: none;
    margin: 0;
    padding: 0.042rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    background: linear-gradient(180deg, rgba(249, 100, 50, 0.06) 2%, rgba(249, 100, 50, 0) 98%);                                                                
    border: 0.083rem solid var(--border-light-orange);
    border-radius: 0.69rem;
}

.hot-game-item {
    display: flex;
    align-items: center;
    padding: 0 0.69rem;
    height: 3.32rem;
}

.hot-game-icon {
    width: 2.16rem;
    height: 2.16rem;
    border-radius: 0.52rem;
    border: 0.083rem solid var(--border-light-gray);
    margin-right: 0.69rem;
    flex-shrink: 0;
}

.hot-game-name {
    flex-grow: 1;
    margin: 0;
    font-size: 1.12rem;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: normal;
}

.hot-game-trial-btn {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 4.62rem;
    height: 1.9rem;
    background-color: var(--accent-color-orange);
    color: var(--text-color-white);
    font-size: 1rem;
    border-radius: 1.02rem;
    flex-shrink: 0;
    margin-left: 1.33rem;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.hot-game-trial-btn:hover {
    background-color: var(--accent-color-orange-dark, #e55a00);
}

/* ============================================
   Search State Styles
   ============================================ */
.loading-item, .no-results-item, .error-item {
    text-align: center;
    padding: 3.32rem 1.66rem;
}

.loading-text, .no-results-text, .error-text {
    color: #666;
    font-size: 1.33rem;
    margin: 0;
}

.loading-text {
    color: #007bff;
}

.error-text {
    color: #dc3545;
}

/* ============================================
   Search Results Section Styles
   ============================================ */
.search-results-section {
    padding: 1.5rem 1.04rem 1.21rem;
    background-color: #fff;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.search-results-title {
    font-size: 1.329rem; /* 16px / 12.037 */
    font-weight: 700;
    color: #333;
    margin: 0 0 0.664rem 0; /* 8px / 12.037 */
    line-height: 1.2;
}

.search-summary {
    background-color: #F2F4F7;
    border: 0.083rem solid #e9ecef;
    border-radius: 0.5rem;
    padding: 0.664rem 1.329rem 0.664rem 0.664rem; /* 8px 16px 8px 8px / 12.037 */
    box-shadow: 0 0.1rem 0.3rem rgba(0, 0, 0, 0.05);
    font-size: 1.1rem;
    color: #222426;
    text-align: left;
    line-height: 1.4;
    display: inline-block;
    width: auto;
    max-width: 100%;
}

.search-keyword {
    color: #ff7a1a;
    font-weight: 600;
}

.search-count {
    color: #ff7a1a;
    font-weight: 600;
}


.search-results-list {
    list-style: none;
    margin-top: 0.664rem; /* 8px / 12.037 */
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.search-result-item {
    display: flex;
    align-items: center;
    padding: 1rem;
    transition: box-shadow 0.2s ease;
}

.search-result-item:hover {
    box-shadow: 0 0.2rem 0.6rem rgba(0, 0, 0, 0.1);
}

.search-result-icon {
    width: 5.562rem; /* 67px / 12.037 */
    height: 5.562rem; /* 67px / 12.037 */
    border-radius: 0.6rem;
    border: 0.083rem solid #e9ecef;
    margin-right: 1rem;
    flex-shrink: 0;
    object-fit: cover;
}

.search-result-info {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.search-result-name {
    font-size: 1.412rem; /* 17px / 12.037 */
    font-weight: 400;
    color: #222426;
    margin: 0;
    line-height: 1.3;
}

.search-result-category {
    font-size: 1.080rem; /* 13px / 12.037 */
    color: #616366;
    margin: 0;
    line-height: 1.2;
}

.search-result-play-btn {
    display: flex;
    justify-content: center;
    align-items: center;
    min-width: 4rem;
    height: 2.2rem;
    background-color: #EAEEF4;
    color: #222426;
    font-size: 0.9rem;
    font-weight: 500;
    border: 0.083rem solid #e9ecef;
    border-radius: 1.295rem; /* 15.6px / 12.037 */
    text-decoration: none;
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin-left: 1rem;
}

.search-result-play-btn:hover {
    background-color: #e9ecef;
    border-color: #dee2e6;
    color: #333;
}

/* ============================================
   Responsive Design
   ============================================ */
@media (orientation: landscape) {
    .hot-games-section {
        max-width: 53.15rem;
        margin: 0 auto;
    }
    
    .search-results-section {
        max-width: 53.15rem;
        margin: 0 auto;
    }
}
.back-button img {
    margin-left: 0;
}

@media screen and (max-width: 375px) {
    .main-container {
        padding:0;
    }
}
