/**
 * ═══════════════════════════════════════════════════════════════════════════
 * KICK ENTEGRASYONU - CSS STYLES
 * ═══════════════════════════════════════════════════════════════════════════
 * 
 * Dosya: /assets/css/kick-integration.css
 * Understrap child theme için Kick styling
 */

/* ═══════════════ CSS DEĞİŞKENLERİ ═══════════════ */
:root {
    --kick-primary: #53FC18;
    --kick-primary-dark: #43CC13;
    --kick-secondary: #8B5CF6;
    --kick-accent: #FF006E;
    --kick-dark: #0A0A0F;
    --kick-darker: #050508;
    --kick-surface: #12121A;
    --kick-surface-light: #1A1A25;
    --kick-text: #FFFFFF;
    --kick-text-muted: #9CA3AF;
    --kick-border: rgba(83, 252, 24, 0.2);
    --kick-glow: 0 0 30px rgba(83, 252, 24, 0.4);
    --kick-radius: 15px;
    --kick-transition: 0.3s ease;
}

/* ═══════════════════════════════════════════════════════════════════════════
   1. KICK PLAYER STYLES
═══════════════════════════════════════════════════════════════════════════ */
.kick-player-container {
    position: relative;
    margin-bottom: 30px;
}

.kick-player-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 oran */
    height: 0;
    overflow: hidden;
    border-radius: var(--kick-radius);
    background: var(--kick-darker);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    border: 1px solid var(--kick-border);
}

.kick-player-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: var(--kick-radius);
}

/* Live Badge */
.kick-live-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    display: none; /* JS ile gösterilecek */
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 0, 0, 0.9);
    border-radius: 50px;
    z-index: 10;
    animation: liveGlow 2s ease-in-out infinite;
}

.kick-live-badge.active {
    display: flex;
}

.kick-live-badge .live-dot {
    width: 10px;
    height: 10px;
    background: #FFFFFF;
    border-radius: 50%;
    animation: livePulse 1.5s ease-in-out infinite;
}

.kick-live-badge .live-text {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    color: #FFFFFF;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

@keyframes livePulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.7; }
}

@keyframes liveGlow {
    0%, 100% { box-shadow: 0 0 10px rgba(255, 0, 0, 0.5); }
    50% { box-shadow: 0 0 25px rgba(255, 0, 0, 0.8); }
}

/* Offline Message */
.kick-offline-message {
    display: none; /* JS ile gösterilecek */
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 30px;
    background: linear-gradient(135deg, var(--kick-surface) 0%, var(--kick-darker) 100%);
    border-radius: var(--kick-radius);
    border: 1px solid var(--kick-border);
}

.kick-offline-message.active {
    display: flex;
}

.kick-offline-message .offline-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.5;
}

.kick-offline-message h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--kick-text);
    margin-bottom: 10px;
}

.kick-offline-message p {
    font-size: 1rem;
    color: var(--kick-text-muted);
    margin-bottom: 25px;
}

.kick-follow-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 30px;
    background: linear-gradient(135deg, var(--kick-primary) 0%, var(--kick-primary-dark) 100%);
    color: var(--kick-darker);
    font-family: 'Rajdhani', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    text-decoration: none;
    border-radius: 50px;
    transition: var(--kick-transition);
    box-shadow: var(--kick-glow);
}

.kick-follow-btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 40px rgba(83, 252, 24, 0.5);
    color: var(--kick-darker);
    text-decoration: none;
}

/* ═══════════════════════════════════════════════════════════════════════════
   2. KICK CHAT STYLES
═══════════════════════════════════════════════════════════════════════════ */
.kick-chat-container {
    background: var(--kick-surface);
    border-radius: var(--kick-radius);
    overflow: hidden;
    border: 1px solid var(--kick-border);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.kick-chat-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px 20px;
    background: var(--kick-surface-light);
    border-bottom: 1px solid rgba(83, 252, 24, 0.1);
}

.kick-chat-header .chat-icon {
    color: var(--kick-primary);
}

.kick-chat-header span {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--kick-text);
}

.kick-chat-header .chat-popout {
    margin-left: auto;
    padding: 8px;
    color: var(--kick-text-muted);
    border-radius: 8px;
    transition: var(--kick-transition);
}

.kick-chat-header .chat-popout:hover {
    color: var(--kick-primary);
    background: rgba(83, 252, 24, 0.1);
}

.kick-chat-wrapper {
    height: 100%;
}

.kick-chat-wrapper iframe {
    display: block;
    width: 100%;
    border: none;
}

/* ═══════════════════════════════════════════════════════════════════════════
   3. KICK STREAM CONTAINER (Player + Chat)
═══════════════════════════════════════════════════════════════════════════ */
.kick-stream-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 25px;
    margin-bottom: 40px;
}

.kick-stream-player {
    min-width: 0;
}

.kick-stream-chat {
    min-width: 0;
}

.kick-stream-chat .kick-chat-container {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.kick-stream-chat .kick-chat-wrapper {
    flex: 1;
}

/* Responsive */
@media (max-width: 992px) {
    .kick-stream-container {
        grid-template-columns: 1fr;
    }
    
    .kick-stream-chat .kick-chat-wrapper iframe {
        height: 400px;
    }
}

/* ═══════════════════════════════════════════════════════════════════════════
   4. KICK CHANNEL CARD
═══════════════════════════════════════════════════════════════════════════ */
.kick-channel-card {
    background: var(--kick-surface);
    border-radius: var(--kick-radius);
    overflow: hidden;
    border: 1px solid var(--kick-border);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    transition: var(--kick-transition);
}

.kick-channel-card:hover {
    transform: translateY(-5px);
    border-color: var(--kick-primary);
    box-shadow: var(--kick-glow), 0 20px 50px rgba(0, 0, 0, 0.4);
}

.kick-channel-card .channel-banner {
    height: 100px;
    background: linear-gradient(135deg, var(--kick-primary) 0%, var(--kick-secondary) 100%);
    opacity: 0.3;
}

.kick-channel-card .channel-content {
    padding: 0 30px 30px;
    text-align: center;
}

.kick-channel-card .channel-avatar {
    width: 100px;
    height: 100px;
    margin: -50px auto 20px;
    border-radius: 50%;
    background: var(--kick-surface-light);
    border: 4px solid var(--kick-surface);
    overflow: hidden;
    position: relative;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.kick-channel-card .channel-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.kick-channel-card .channel-avatar img.loaded {
    display: block;
}

.kick-channel-card .channel-avatar .avatar-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', sans-serif;
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--kick-primary);
    background: linear-gradient(135deg, var(--kick-surface) 0%, var(--kick-darker) 100%);
}

.kick-channel-card .channel-name {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--kick-text);
    margin-bottom: 8px;
}

.kick-channel-card .channel-bio {
    font-size: 0.95rem;
    color: var(--kick-text-muted);
    margin-bottom: 20px;
    line-height: 1.6;
}

.kick-channel-card .channel-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-bottom: 25px;
    padding: 20px;
    background: var(--kick-darker);
    border-radius: 12px;
}

.kick-channel-card .stat {
    text-align: center;
}

.kick-channel-card .stat-value {
    display: block;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--kick-text);
    margin-bottom: 5px;
}

.kick-channel-card .stat-label {
    font-size: 0.8rem;
    color: var(--kick-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.kick-channel-card .live-status {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.kick-channel-card .status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.kick-channel-card .status-dot.offline {
    background: #6B7280;
}

.kick-channel-card .status-dot.live {
    background: #FF0000;
    animation: livePulse 1.5s ease-in-out infinite;
}

.kick-channel-card .channel-follow-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 35px;
    background: linear-gradient(135deg, var(--kick-primary) 0%, var(--kick-primary-dark) 100%);
    color: var(--kick-darker);
    font-family: 'Rajdhani', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    text-decoration: none;
    border-radius: 50px;
    transition: var(--kick-transition);
    box-shadow: var(--kick-glow);
}

.kick-channel-card .channel-follow-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 40px rgba(83, 252, 24, 0.5);
    color: var(--kick-darker);
    text-decoration: none;
}

/* ═══════════════════════════════════════════════════════════════════════════
   5. KICK SCHEDULE STYLES
═══════════════════════════════════════════════════════════════════════════ */
.kick-schedule {
    background: var(--kick-surface);
    border-radius: var(--kick-radius);
    padding: 30px;
    border: 1px solid var(--kick-border);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.kick-schedule .schedule-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--kick-text);
    text-align: center;
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(83, 252, 24, 0.1);
}

.kick-schedule .schedule-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.kick-schedule .schedule-item {
    display: flex;
    align-items: center;
    padding: 18px 25px;
    background: var(--kick-darker);
    border-radius: 12px;
    border: 1px solid transparent;
    transition: var(--kick-transition);
}

.kick-schedule .schedule-item:hover {
    transform: translateX(10px);
    border-color: var(--kick-primary);
    box-shadow: -5px 0 20px rgba(83, 252, 24, 0.2);
}

.kick-schedule .schedule-item.active {
    background: linear-gradient(135deg, rgba(83, 252, 24, 0.1) 0%, rgba(139, 92, 246, 0.05) 100%);
    border-color: var(--kick-primary);
}

.kick-schedule .schedule-day {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--kick-primary);
    width: 120px;
    flex-shrink: 0;
}

.kick-schedule .schedule-time {
    font-family: 'Rajdhani', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--kick-text);
    width: 140px;
    flex-shrink: 0;
}

.kick-schedule .schedule-game {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.95rem;
    color: var(--kick-text-muted);
    flex: 1;
}

.kick-schedule .status-live,
.kick-schedule .status-upcoming {
    padding: 6px 16px;
    border-radius: 50px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.kick-schedule .status-live {
    background: rgba(255, 0, 0, 0.15);
    color: #FF4444;
    animation: liveGlow 2s ease-in-out infinite;
}

.kick-schedule .status-upcoming {
    background: rgba(139, 92, 246, 0.15);
    color: #A78BFA;
}

/* Schedule Responsive */
@media (max-width: 768px) {
    .kick-schedule .schedule-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding: 15px 20px;
    }
    
    .kick-schedule .schedule-day,
    .kick-schedule .schedule-time {
        width: auto;
    }
    
    .kick-schedule .status-live,
    .kick-schedule .status-upcoming {
        align-self: flex-start;
    }
}

/* ═══════════════════════════════════════════════════════════════════════════
   6. VIEWER COUNT BADGE
═══════════════════════════════════════════════════════════════════════════ */
.kick-viewer-count {
    position: absolute;
    top: 15px;
    right: 15px;
    display: none; /* JS ile gösterilecek */
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 50px;
    z-index: 10;
    backdrop-filter: blur(10px);
}

.kick-viewer-count.active {
    display: flex;
}

.kick-viewer-count svg {
    width: 16px;
    height: 16px;
    color: var(--kick-text-muted);
}

.kick-viewer-count span {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--kick-text);
}

/* ═══════════════════════════════════════════════════════════════════════════
   7. LOADING STATES
═══════════════════════════════════════════════════════════════════════════ */
.kick-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 30px;
    background: var(--kick-surface);
    border-radius: var(--kick-radius);
}

.kick-loading-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid var(--kick-surface-light);
    border-top-color: var(--kick-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

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

.kick-loading-text {
    font-family: 'Rajdhani', sans-serif;
    font-size: 1rem;
    color: var(--kick-text-muted);
}

/* ═══════════════════════════════════════════════════════════════════════════
   8. DARK MODE ADJUSTMENTS (Bootstrap Uyumluluğu)
═══════════════════════════════════════════════════════════════════════════ */
.kick-player-container,
.kick-chat-container,
.kick-channel-card,
.kick-schedule {
    color-scheme: dark;
}

/* Bootstrap ile çakışma önleme */
.kick-player-container *,
.kick-chat-container *,
.kick-channel-card *,
.kick-schedule * {
    box-sizing: border-box;
}

/* ═══════════════════════════════════════════════════════════════════════════
   9. ANIMASYONLAR
═══════════════════════════════════════════════════════════════════════════ */
@keyframes kickFadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.kick-player-container,
.kick-chat-container,
.kick-channel-card,
.kick-schedule {
    animation: kickFadeIn 0.6s ease-out;
}

/* ═══════════════════════════════════════════════════════════════════════════
   10. PRINT STYLES
═══════════════════════════════════════════════════════════════════════════ */
@media print {
    .kick-player-container,
    .kick-chat-container {
        display: none;
    }
    
    .kick-channel-card,
    .kick-schedule {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}
