/* ========== Главная страница ========== */

.content.items_main {
  padding-top: 6px;
}

/* ========== Поиск ========== */
.content-wrapper {
    min-height: 500px;
    padding: 20px 0;
}

.search-wrapper {
    margin-bottom: 30px;
    position: relative;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.search-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    pointer-events: none;
    z-index: 2;
}

.search-input {
    width: 100%;
    padding: 16px 20px 16px 50px;
    background: #1e1e1e;
    border: 1px solid #333;
    border-radius: 50px;
    color: #fff;
    font-size: 16px;
    outline: none;
    transition: all 0.3s ease;
    font-family: inherit;
}

.search-input:focus {
    border-color: #ffb50e;
    box-shadow: 0 0 0 3px rgba(255,181,14,0.2);
    background: #252525;
}

.search-input::placeholder {
    color: #666;
}

.search-clear {
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #888;
    font-size: 18px;
    transition: color 0.2s;
    display: none;
}

.search-clear:hover {
    color: #ffb50e;
}

.search-stats {
    text-align: center;
    margin-top: 12px;
    font-size: 13px;
    color: #ffb50e;
}

/* ========== Сетка категорий (wgc) ========== */
.wgc {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.wgc-item {
    background: linear-gradient(145deg, #1e1e1e, #181818);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(255,255,255,0.05);
    position: relative;
}

.wgc-item.hidden-category {
    display: none;
}

.wgc-item:hover {
    transform: translateY(-5px);
    border-color: rgba(255,181,14,0.3);
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
}

.wgc-item a {
    text-decoration: none;
    display: flex;
    align-items: center;
    padding: 18px 20px;
    gap: 15px;
}

.wgc-item-img {
    width: 55px;
    height: 55px;
    border-radius: 14px;
    flex-shrink: 0;
    overflow: hidden;
    background: #2a2a2a;
}

.wgc-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.wgc-item:hover .wgc-item-img img {
    transform: scale(1.1);
}

.wgc-item-cnt {
    flex: 1;
}

.wgc-item-cnt h2 {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 5px 0;
    color: #fff;
    letter-spacing: -0.3px;
}

.deal-count {
    display: inline-block;
    background: rgba(255,181,14,0.15);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    color: #ffb50e;
}

/* ========== Сетка новостей ========== */
.news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin: 20px 0;
}

.news-card {
    background: #1a1a1a;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #2a2a2a;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    border-color: #3a3a3a;
}

.news-card a {
    text-decoration: none;
    color: inherit;
    display: block;
}

.news-card-img {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.news-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.news-card:hover .news-card-img img {
    transform: scale(1.05);
}

.news-card-content {
    padding: 20px;
}

.news-date {
    display: block;
    font-size: 13px;
    color: #888;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.news-card-content h3 {
    font-size: 17px;
    font-weight: 600;
    color: #fff;
    margin: 0 0 10px 0;
    line-height: 1.4;
}

.news-card-content p {
    font-size: 14px;
    color: #aaa;
    margin: 0;
    line-height: 1.5;
}

/* ========== Сетка Steam-игр ========== */
.steam-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
    margin: 20px 0;
    padding: 0 0px;
    max-width: 100%;
    box-sizing: border-box;
}

.steam-card {
    background: #1a1a1a;
    border-radius: 6px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #2a2a2a;
    min-width: 0;
}

.steam-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
    border-color: #3a3a3a;
}

.steam-card a {
    text-decoration: none;
    color: inherit;
    display: block;
}

.steam-card-img {
    width: 100%;
    aspect-ratio: 2 / 3;
    overflow: hidden;
}

.steam-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.steam-card:hover .steam-card-img img {
    transform: scale(1.05);
}

.steam-card-cnt {
    padding: 6px 8px;
    text-align: center;
}

.steam-card-cnt h3 {
    font-size: 10px;
    font-weight: 600;
    color: #fff;
    margin: 0 0 2px 0;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.steam-card-cnt span {
    font-size: 9px;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ========== Анимация карточек ========== */
.wgc-item {
    animation: fadeInUp 0.4s ease backwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========== Адаптив ========== */
@media (max-width: 992px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .wgc {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    .wgc-item a {
        padding: 12px 12px;
        gap: 10px;
    }
    .wgc-item-img {
        width: 45px;
        height: 45px;
    }
    .wgc-item-cnt h2 {
        font-size: 13px;
    }
    .deal-count {
        font-size: 10px;
        padding: 2px 8px;
    }
}

@media (max-width: 600px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    .news-card-img {
        height: 120px;
    }
    .news-card-content {
        padding: 12px;
    }
    .news-card-content h3 {
        font-size: 13px;
        margin-bottom: 6px;
    }
    .news-card-content p {
        font-size: 11px;
        line-height: 1.3;
    }
    .news-date {
        font-size: 10px;
        margin-bottom: 6px;
    }
    
    .steam-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
        padding: 0 0px;
    }
    .steam-card-cnt {
        padding: 5px 6px;
    }
    .steam-card-cnt h3 {
        font-size: 10px;
    }
    .steam-card-cnt span {
        font-size: 9px;
    }
}

@media (max-width: 480px) {
    .wgc {
        gap: 10px;
    }
    .wgc-item a {
        padding: 10px 10px;
    }
    .wgc-item-img {
        width: 40px;
        height: 40px;
    }
    .wgc-item-cnt h2 {
        font-size: 12px;
    }
}