.grid-container { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px,1fr)); gap: 30px 10px; padding: 100px 4% 40px; }
.grid-item { transition: transform 0.3s; cursor: pointer; }
.grid-item:hover { transform: scale(1.1); z-index: 5; }
.grid-item img { width: 100%; border-radius: 4px; }

.results-page {
    padding: 90px 4% 60px;
    min-height: 100vh;
    animation: fadeInPage 0.35s ease;
}

.results-header { margin-bottom: 24px; }

.results-heading {
    font-size: 1.8rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.25;
}

.results-heading .rh-label {
    color: #808080;
    font-weight: 400;
    font-size: 1rem;
    display: block;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.results-heading .rh-query { color: var(--primary-color); }

.results-count {
    margin-top: 6px;
    font-size: 0.88rem;
    color: #606060;
}

.results-filter-bar {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    gap: 8px;
    margin-bottom: 24px;
    padding-bottom: 18px;
    border-bottom: 1px solid #222;
}
.results-filter-bar::-webkit-scrollbar { display: none; }

.filter-label {
    font-size: 0.78rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 600;
    margin-right: 2px;
    white-space: nowrap;
}

.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 14px;
    border-radius: 20px;
    border: 1px solid #333;
    background: transparent;
    color: #aaa;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.18s ease;
    white-space: nowrap;
    font-family: inherit;
    line-height: 1;
}
.filter-chip:hover { border-color: #aaa; color: #fff; background: rgba(255,255,255,0.05); }
.filter-chip.active { background: var(--primary-color); border-color: var(--primary-color); color: #fff; }

.results-sort {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.sort-select {
    background: #1c1c1c;
    color: #bbb;
    border: 1px solid #333;
    border-radius: 5px;
    padding: 5px 28px 5px 10px;
    font-size: 0.8rem;
    font-family: inherit;
    cursor: pointer;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='9' height='5'%3E%3Cpath d='M0 0l4.5 5L9 0z' fill='%23666'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 9px center;
    transition: border-color 0.2s, color 0.2s;
}
.sort-select:hover, .sort-select:focus { border-color: #555; color: #fff; }

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
    gap: 22px 10px;
}

.result-card {
    position: relative;
    cursor: pointer;
    border-radius: 5px;
    overflow: hidden;
    background: #1a1a1a;
    transition: transform 0.3s cubic-bezier(0.2, 1, 0.2, 1), box-shadow 0.3s ease;
    animation: cardReveal 0.4s ease both;
}

.result-card:nth-child(1)  { animation-delay: 0.03s; }
.result-card:nth-child(2)  { animation-delay: 0.06s; }
.result-card:nth-child(3)  { animation-delay: 0.09s; }
.result-card:nth-child(4)  { animation-delay: 0.12s; }
.result-card:nth-child(5)  { animation-delay: 0.15s; }
.result-card:nth-child(6)  { animation-delay: 0.18s; }
.result-card:nth-child(7)  { animation-delay: 0.21s; }
.result-card:nth-child(8)  { animation-delay: 0.24s; }
.result-card:nth-child(n+9){ animation-delay: 0.27s; }

@media (hover: hover) {
    .result-card:hover {
        transform: scale(1.07);
        box-shadow: 0 12px 32px rgba(0,0,0,0.75);
        z-index: 10;
    }
}

.result-card-poster {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    display: block;
    background: #1f1f1f;
}

.result-card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.95) 0%, rgba(0,0,0,0) 52%);
    opacity: 0;
    transition: opacity 0.28s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 12px 10px;
    gap: 7px;
}
@media (hover: hover) { .result-card:hover .result-card-overlay { opacity: 1; } }

.result-card-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.result-card-meta {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 0.7rem;
    color: #aaa;
}

.result-card-type {
    background: var(--primary-color);
    color: #fff;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.result-card-actions { display: flex; gap: 5px; }

.result-skeleton {
    border-radius: 5px;
    aspect-ratio: 2 / 3;
    background: linear-gradient(90deg, #1a1a1a 25%, #232323 50%, #1a1a1a 75%);
    background-size: 800px 100%;
    animation: shimmer 1.4s infinite linear;
}

.results-empty {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 70px 20px;
    text-align: center;
}
.results-empty-icon { font-size: 3.5rem; margin-bottom: 18px; opacity: 0.3; }
.results-empty-title { font-size: 1.3rem; font-weight: 700; color: #fff; margin-bottom: 8px; }
.results-empty-subtitle { font-size: 0.9rem; color: #555; max-width: 380px; line-height: 1.6; }
.results-empty-clear {
    margin-top: 22px;
    padding: 9px 26px;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.2s;
}
.results-empty-clear:hover { background: #c40812; }

.load-more-wrap {
    display: flex;
    justify-content: center;
    margin-top: 44px;
}
.load-more-btn {
    padding: 11px 44px;
    background: transparent;
    color: #bbb;
    border: 1px solid #444;
    border-radius: 4px;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    letter-spacing: 0.04em;
    transition: all 0.2s;
}
.load-more-btn:hover { border-color: #fff; color: #fff; background: rgba(255,255,255,0.05); }
