/**
 * HLTV Streams Shortcode Styles — AdriaZone Design System
 *
 * Matches design tokens from:
 *   hltv-news-style.css        (list/row pattern)
 *   hltv-tournament-style.css  (card system, borders)
 *   hltv-profile-style.css     (color variables)
 */

/* ============================================
   Streams List — Row Layout (default)
   ============================================ */
.hltv-streams-list {
    display: flex;
    flex-direction: column;
    background: #161a21;
    border: 1px solid #30363d;
    border-radius: 10px;
    overflow: hidden;
}

/* ── Grid layout variant ── */
.hltv-streams-list.hltv-streams-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 12px;
    background: transparent;
    border: none;
    border-radius: 0;
    overflow: visible;
}

/* ============================================
   Stream Item
   ============================================ */
.hltv-stream-item {
    display: flex;
    flex-direction: column;
    background: #161a21;
    border-bottom: 1px solid #21262d;
    cursor: pointer;
    transition: background .15s;
    text-decoration: none !important;
    color: inherit;
}

.hltv-streams-list:not(.hltv-streams-grid) .hltv-stream-item {
    flex-direction: row;
    align-items: center;
}

.hltv-stream-item:last-child {
    border-bottom: none;
}

.hltv-stream-item:hover {
    background: #1c2333;
    text-decoration: none !important;
}

.hltv-stream-item:hover .hltv-stream-name {
    color: #e94560;
}

/* Grid card style */
.hltv-streams-grid .hltv-stream-item {
    background: #161a21;
    border: 1px solid #30363d;
    border-radius: 10px;
    overflow: hidden;
    border-bottom: 1px solid #30363d;
    transition: border-color .15s, transform .15s;
}

.hltv-streams-grid .hltv-stream-item:hover {
    border-color: #e94560;
    transform: translateY(-2px);
    background: #1a1f2a;
}

/* Offline */
.hltv-stream-item.hltv-stream-offline { opacity: 0.55; }
.hltv-stream-item.hltv-stream-offline:hover { opacity: 0.8; }

/* ============================================
   Thumbnail (Grid only)
   ============================================ */
.hltv-stream-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #0d1117;
}

.hltv-stream-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .3s ease;
    display: block;
}

.hltv-stream-item:hover .hltv-stream-thumb img {
    transform: scale(1.04);
}

.hltv-stream-live-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: #e94560;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 3px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 6px rgba(233,69,96,.4);
}

.hltv-stream-viewers-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0,0,0,.75);
    color: #e6edf3;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 3px;
    display: flex;
    align-items: center;
    gap: 4px;
    backdrop-filter: blur(4px);
}

/* ============================================
   Info Row
   ============================================ */
.hltv-stream-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.hltv-stream-info-left {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    flex: 1;
}

.hltv-stream-info-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

/* ── Live dot ── */
.hltv-stream-live-dot {
    width: 7px;
    height: 7px;
    background: #e94560;
    border-radius: 50%;
    flex-shrink: 0;
    animation: hltv-stream-pulse 2s ease-in-out infinite;
    box-shadow: 0 0 6px rgba(233,69,96,.5);
}

@keyframes hltv-stream-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.5; transform: scale(0.85); }
}

/* ── Platform icon ── */
.hltv-stream-platform { display: flex; align-items: center; flex-shrink: 0; }
.hltv-stream-platform-icon { color: #6e7681; }
.hltv-stream-platform-icon.hltv-twitch  { color: #9146ff; }
.hltv-stream-platform-icon.hltv-youtube { color: #ff0000; }
.hltv-stream-platform-icon.hltv-kick    { color: #53fc18; }

/* ── Flag ── */
.hltv-stream-flag {
    width: 20px;
    height: 15px;
    border-radius: 2px;
    box-shadow: 0 1px 3px rgba(0,0,0,.4);
    flex-shrink: 0;
    object-fit: cover;
}

/* ── Stream name + game ── */
.hltv-stream-details {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.hltv-stream-name {
    font-size: 13px;
    color: #c9d1d9;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color .15s;
    line-height: 1.3;
}

.hltv-stream-game {
    font-size: 11px;
    color: #6e7681;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
    margin-top: 1px;
}

/* ── Language badge ── */
.hltv-stream-lang {
    font-size: 10px;
    color: #8fa3b3;
    background: #1c2333;
    border: 1px solid #30363d;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* ── Viewer count ── */
.hltv-stream-viewer-count {
    font-size: 12px;
    color: #e94560;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
    font-variant-numeric: tabular-nums;
    flex-shrink: 0;
}

/* ── Empty state ── */
.hltv-streams-empty {
    padding: 40px 20px;
    text-align: center;
    color: #6e7681;
    font-size: 13px;
    background: #161a21;
    border: 1px solid #30363d;
    border-radius: 10px;
}

/* ============================================
   Sidebar Streams
   ============================================ */
.hltv-streams-sidebar-list {
    display: flex;
    flex-direction: column;
    background: #161a21;
    border: 1px solid #30363d;
    border-radius: 10px;
    overflow: hidden;
}

.hltv-stream-sidebar-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 11px 14px;
    cursor: pointer;
    transition: background .15s;
    border-bottom: 1px solid #21262d;
    text-decoration: none !important;
    color: inherit;
}

.hltv-stream-sidebar-item:last-child { border-bottom: none; }

.hltv-stream-sidebar-item:hover {
    background: #1c2333;
    text-decoration: none !important;
}

.hltv-stream-sidebar-item:hover .hltv-stream-sidebar-name {
    color: #e94560;
}

.hltv-stream-sidebar-name {
    font-size: 13px;
    color: #c9d1d9;
    font-weight: 500;
    flex: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color .15s;
}

.hltv-stream-sidebar-viewers {
    font-size: 11px;
    color: #e94560;
    font-weight: 600;
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
}

.hltv-streams-empty-sidebar {
    padding: 16px;
    text-align: center;
    color: #6e7681;
    font-size: 12px;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 768px) {
    .hltv-streams-list.hltv-streams-grid {
        grid-template-columns: 1fr;
    }
    .hltv-stream-info { padding: 10px 12px; }
    .hltv-stream-name { font-size: 13px; }
    .hltv-stream-game { display: none; }
}
