/**
 * Widget Styles
 * Modern and attractive sidebar widgets
 */

/* ===================== BASE WIDGET STYLES ===================== */

.widget {
    background: white;
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.widget-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 16px 0;
    font-size: 16px;
    font-weight: 700;
    color: #1f2937;
}

.widget-title i {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border-radius: 8px;
    color: #16a34a;
    font-size: 14px;
}

/* ===================== GAMES LIST WIDGET ===================== */

.widget-games-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.widget-game-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    background: #f9fafb;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.25s ease;
}

.widget-game-item:hover {
    background: #f7fef9;
    transform: translateX(4px);
}

.widget-game-rank {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
}

.widget-game-item:nth-child(1) .widget-game-rank {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.widget-game-item:nth-child(2) .widget-game-rank {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
}

.widget-game-item:nth-child(3) .widget-game-rank {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
}

.widget-game-thumb {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    overflow: hidden;
    flex-shrink: 0;
}

.widget-game-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.widget-game-info {
    flex: 1;
    min-width: 0;
}

.widget-game-title {
    margin: 0 0 4px 0;
    font-size: 13px;
    font-weight: 600;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.widget-game-item:hover .widget-game-title {
    color: #16a34a;
}

.widget-game-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px;
    color: #6b7280;
}

.widget-game-rating {
    display: flex;
    align-items: center;
    gap: 4px;
}

.widget-game-rating i {
    color: #fbbf24;
    font-size: 10px;
}

.widget-game-date {
    display: flex;
    align-items: center;
    gap: 4px;
}

.widget-game-version {
    padding: 2px 6px;
    background: #e5e7eb;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
}

/* ===================== CATEGORIES WIDGET ===================== */

.widget-categories-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.widget-cat-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    background: #f9fafb;
    border-radius: 10px;
    text-decoration: none;
    transition: all 0.25s ease;
}

.widget-cat-item:hover {
    background: var(--cat-color, #16a34a);
}

.widget-cat-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--cat-color, #16a34a);
    border-radius: 8px;
    color: white;
    font-size: 14px;
    transition: all 0.25s;
}

.widget-cat-item:hover .widget-cat-icon {
    background: white;
    color: var(--cat-color, #16a34a);
}

.widget-cat-name {
    flex: 1;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    transition: color 0.25s;
}

.widget-cat-item:hover .widget-cat-name {
    color: white;
}

.widget-cat-count {
    padding: 4px 10px;
    background: #e5e7eb;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    transition: all 0.25s;
}

.widget-cat-item:hover .widget-cat-count {
    background: rgba(255,255,255,0.3);
    color: white;
}

/* ===================== GAMES GRID WIDGET ===================== */

.widget-games-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.widget-game-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    text-align: center;
}

.widget-game-card-thumb {
    aspect-ratio: 1;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.25s;
}

.widget-game-card:hover .widget-game-card-thumb {
    transform: translateY(-4px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

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

.widget-game-card-title {
    font-size: 11px;
    font-weight: 500;
    color: #374151;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.3;
}

.widget-game-card:hover .widget-game-card-title {
    color: #16a34a;
}

/* ===================== TELEGRAM WIDGET ===================== */

.widget-telegram {
    text-align: center;
    padding: 24px 20px;
    background: linear-gradient(135deg, #e0f2fe 0%, #bae6fd 100%);
    border-radius: 16px;
}

.widget-telegram-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0088cc 0%, #00aaee 100%);
    border-radius: 50%;
    font-size: 28px;
    color: white;
}

.widget-telegram-title {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 700;
    color: #0369a1;
}

.widget-telegram-text {
    margin: 0 0 16px 0;
    font-size: 13px;
    color: #0c4a6e;
    line-height: 1.5;
}

.widget-telegram-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: linear-gradient(135deg, #0088cc 0%, #00aaee 100%);
    border-radius: 10px;
    color: white;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.25s;
}

.widget-telegram-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,136,204,0.35);
    color: white;
}

/* ===================== RESPONSIVE ===================== */

@media (max-width: 1024px) {
    .game-sidebar .widget {
        margin-bottom: 16px;
    }
}

@media (max-width: 768px) {
    .widget-games-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 480px) {
    .widget-games-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}


