/* ===== Search Page Styles ===== */

/* ===== Search Header ===== */
.search-header {
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--accent-color) 100%);
    color: #fff;
    padding: 60px 0;
    margin-bottom: 40px;
}

.search-header-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.search-header h1 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 15px;
}

.search-header p {
    font-size: 16px;
    opacity: 0.9;
    margin-bottom: 30px;
}

/* ===== Search Form ===== */
.search-form-container {
    max-width: 700px;
    margin: 0 auto 50px;
    padding: 0 20px;
}

.search-form {
    display: flex;
    background: #fff;
    border-radius: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.search-form input {
    flex: 1;
    border: none;
    padding: 18px 25px;
    font-size: 16px;
    outline: none;
}

.search-form button {
    background: var(--primary-color);
    color: #fff;
    border: none;
    padding: 18px 35px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.search-form button:hover {
    background: #c92a36;
}

/* ===== Search Results ===== */
.search-results-container {
    max-width: 1200px;
    margin: 0 auto 60px;
    padding: 0 20px;
}

.search-results-info {
    margin-bottom: 30px;
    padding: 15px 20px;
    background: var(--light-color);
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.search-results-info h2 {
    font-size: 18px;
    color: var(--secondary-color);
}

.search-results-info span {
    color: var(--text-light);
    font-size: 14px;
}

/* ===== No Results ===== */
.no-results {
    text-align: center;
    padding: 60px 20px;
    background: #fff;
    border-radius: 10px;
    box-shadow: var(--shadow);
    margin-bottom: 40px;
}

.no-results-icon {
    font-size: 60px;
    color: var(--text-light);
    margin-bottom: 20px;
}

.no-results h3 {
    font-size: 24px;
    color: var(--secondary-color);
    margin-bottom: 10px;
}

.no-results p {
    color: var(--text-light);
    margin-bottom: 20px;
}

.no-results-tips {
    text-align: left;
    max-width: 500px;
    margin: 0 auto;
}

.no-results-tips h4 {
    font-size: 16px;
    color: var(--secondary-color);
    margin-bottom: 15px;
}

.no-results-tips ul {
    list-style: none;
}

.no-results-tips li {
    padding: 8px 0;
    color: var(--text-light);
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.no-results-tips li::before {
    content: '•';
    color: var(--primary-color);
    font-size: 20px;
}

/* ===== Results Grid ===== */
.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 25px;
}

.result-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.result-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.result-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.result-content {
    padding: 20px;
}

.result-category {
    display: inline-block;
    background: var(--primary-color);
    color: #fff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 10px;
}

.result-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 10px;
    line-height: 1.4;
}

.result-title a {
    color: inherit;
}

.result-title a:hover {
    color: var(--primary-color);
}

.result-excerpt {
    color: var(--text-light);
    font-size: 14px;
    margin-bottom: 15px;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.result-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #999;
}

.result-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* ===== Recommended Section ===== */
.recommended-section {
    margin: 60px auto;
}

.recommended-section .section-title {
    margin-bottom: 30px;
}

/* ===== Pagination ===== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.pagination a,
.pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
}

.pagination a {
    background: #fff;
    color: var(--secondary-color);
    box-shadow: var(--shadow);
}

.pagination a:hover {
    background: var(--primary-color);
    color: #fff;
}

.pagination span.active {
    background: var(--primary-color);
    color: #fff;
}

.pagination span.disabled {
    background: #f5f5f5;
    color: #ccc;
    cursor: not-allowed;
}

/* ===== Loading State ===== */
.loading {
    text-align: center;
    padding: 60px 20px;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading p {
    color: var(--text-light);
    font-size: 16px;
}

/* ===== Mobile Responsive ===== */
@media (max-width: 768px) {
    .search-header h1 {
        font-size: 28px;
    }

    .search-form {
       
        border-radius: 15px;
    }

    .search-form input {
        border-bottom: 1px solid var(--border-color);
    }

    .search-form button {
        border-radius: 0 0 15px 15px;
        padding: 15px;
    }

    .search-results-info {
        flex-direction: column;
        align-items: flex-start;
    }

    .results-grid {
        grid-template-columns: 1fr;
    }

    .pagination {
        gap: 5px;
    }

    .pagination a,
    .pagination span {
        width: 35px;
        height: 35px;
        font-size: 13px;
    }
}
