<?xml version="1.0" encoding="UTF-8"?>
<window>
    <onload condition="Skin.HasSetting(MilionarDefaultsV1)">SetProperty(milionar.logo.tint,$VAR[MilionarLogoTint],home)</onload>
    <onload condition="!Skin.HasSetting(MilionarDefaultsV1)">SetProperty(milionar.logo.tint,FFFFFFFF,home)</onload>
    <onload condition="Skin.HasSetting(MilionarDefaultsV1)">SetProperty(milionar.logo.wordmark,$VAR[MilionarWordmark],home)</onload>
    <onload condition="!Skin.HasSetting(MilionarDefaultsV1)">SetProperty(milionar.logo.wordmark,FFFFF5E5,home)</onload>

    <!-- defaultcontrol removed - focus is set by Python after items are loaded -->
    <onload>SetProperty(WCS.AIChat.Title,MyTV - televize budoucnosti)</onload>
    <onload>SetProperty(WCS.AIChat.Status,Připraven)</onload>
    <!-- Default fanart fallback -->
    <onload>SetProperty(WCS.AIPreview.Fanart,special://home/addons/plugin.video.milionar/resources/media/fanart_fallback.jpg)</onload>
    
    <!-- Animace při otevření/zavření dialogu -->
    <animation effect="fade" start="0" end="100" time="400" tween="cubic" easing="out">WindowOpen</animation>
    <animation effect="fade" start="100" end="0" time="300" tween="cubic" easing="in">WindowClose</animation>
    
    <controls>
        <!-- ==================================================================================== -->
        <!-- BACKGROUND LAYER -->
        <!-- ==================================================================================== -->
        
        <!-- ==================================================================================== -->
        <!-- LOADING MATTE LAYER - Base layer, always at the bottom -->
        <!-- Visible for dynamic modes (Fanart/Still/Collages) until Ready is set -->
        <!-- Static mode doesn't use Matte - shows immediately -->
        <!-- ==================================================================================== -->
        <control type="image">
            <left>0</left>
            <top>0</top>
            <width>1920</width>
            <height>1080</height>
            <texture colordiffuse="FF0A0A0F">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
            <visible>true</visible>
            <!-- ALWAYS visible - backgrounds fade in over it, never disappears -->
        </control>
        
        <!-- Mode 0: Static Background -->
        <!-- Style 0 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">special://home/addons/plugin.video.milionar/resources/media/hub_background_v2.jpg</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),0) + [String.IsEmpty(Window.Property(WCS.MyTV.AnimStyle)) | String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),0)]</visible>
            <animation effect="zoom" start="100" end="106" time="45000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="30,15" time="45000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 1 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">special://home/addons/plugin.video.milionar/resources/media/hub_background_v2.jpg</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),0) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),1)</visible>
            <animation effect="zoom" start="100" end="150" time="30000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 2 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">special://home/addons/plugin.video.milionar/resources/media/hub_background_v2.jpg</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),0) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),2)</visible>
            <animation effect="slide" start="-40,0" end="40,0" time="50000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 3 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">special://home/addons/plugin.video.milionar/resources/media/hub_background_v2.jpg</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),0) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),3)</visible>
            <animation effect="zoom" start="100" end="115" time="25000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="50,30" time="25000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 4 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">special://home/addons/plugin.video.milionar/resources/media/hub_background_v2.jpg</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),0) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),4)</visible>
            <animation effect="zoom" start="100" end="108" time="40000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="-35,20" time="40000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        
        <!-- Mode 1: Fanart (no effects, fallback) -->
        <!-- Style 0 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Container(9000).ListItem.Art(fanart)]</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),1) + String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + [String.IsEmpty(Window.Property(WCS.MyTV.AnimStyle)) | String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),0)]</visible>
            <animation effect="zoom" start="100" end="106" time="45000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="30,15" time="45000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 1 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Container(9000).ListItem.Art(fanart)]</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),1) + String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),1)</visible>
            <animation effect="zoom" start="100" end="150" time="30000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 2 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Container(9000).ListItem.Art(fanart)]</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),1) + String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),2)</visible>
            <animation effect="slide" start="-40,0" end="40,0" time="50000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 3 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Container(9000).ListItem.Art(fanart)]</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),1) + String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),3)</visible>
            <animation effect="zoom" start="100" end="115" time="25000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="50,30" time="25000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 4 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Container(9000).ListItem.Art(fanart)]</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),1) + String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),4)</visible>
            <animation effect="zoom" start="100" end="108" time="40000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="-35,20" time="40000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        
        <!-- Mode 2: Still (no effects, fallback) -->
        <!-- Style 0 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Container(9000).ListItem.Art(thumb)]</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),2) + String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + [String.IsEmpty(Window.Property(WCS.MyTV.AnimStyle)) | String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),0)]</visible>
            <animation effect="zoom" start="100" end="106" time="45000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="-30,15" time="45000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 1 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Container(9000).ListItem.Art(thumb)]</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),2) + String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),1)</visible>
            <animation effect="zoom" start="100" end="150" time="30000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 2 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Container(9000).ListItem.Art(thumb)]</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),2) + String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),2)</visible>
            <animation effect="slide" start="40,0" end="-40,0" time="50000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 3 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Container(9000).ListItem.Art(thumb)]</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),2) + String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),3)</visible>
            <animation effect="zoom" start="100" end="115" time="25000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="-50,30" time="25000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 4 -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Container(9000).ListItem.Art(thumb)]</texture>
            <aspectratio>scale</aspectratio>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.BackgroundMode),2) + String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),4)</visible>
            <animation effect="zoom" start="100" end="108" time="40000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="35,20" time="40000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        
        <!-- CUSTOM PROCESSED BACKGROUND (with blur/glow effects from Python) - renders ON TOP of raw backgrounds -->
        <!-- Style 0: Jemný dech (Default) - visible if style is 0 or empty -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Window.Property(WCS.MyTV.Background.Custom)]</texture>
            <aspectratio>scale</aspectratio>
            <fadetime>600</fadetime>
            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + [String.IsEmpty(Window.Property(WCS.MyTV.AnimStyle)) | String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),0)]</visible>
            <animation effect="zoom" start="100" end="106" time="45000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="30,15" time="45000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 1: Pulzující srdce -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Window.Property(WCS.MyTV.Background.Custom)]</texture>
            <aspectratio>scale</aspectratio>
            <fadetime>600</fadetime>
            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),1)</visible>
            <animation effect="zoom" start="100" end="150" time="30000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 2: Plynoucí tok -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Window.Property(WCS.MyTV.Background.Custom)]</texture>
            <aspectratio>scale</aspectratio>
            <fadetime>600</fadetime>
            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),2)</visible>
            <animation effect="slide" start="-40,0" end="40,0" time="50000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 3: Dynamická vlna -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Window.Property(WCS.MyTV.Background.Custom)]</texture>
            <aspectratio>scale</aspectratio>
            <fadetime>600</fadetime>
            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),3)</visible>
            <animation effect="zoom" start="100" end="115" time="25000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="50,30" time="25000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        <!-- Style 4: Zrcadlový odraz -->
        <control type="image">
            <left>-50</left>
            <top>-30</top>
            <width>2020</width>
            <height>1140</height>
            <texture background="true">$INFO[Window.Property(WCS.MyTV.Background.Custom)]</texture>
            <aspectratio>scale</aspectratio>
            <fadetime>600</fadetime>
            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.Background.Custom)) + String.IsEqual(Window.Property(WCS.MyTV.AnimStyle),4)</visible>
            <animation effect="zoom" start="100" end="108" time="40000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
            <animation effect="slide" start="0,0" end="-35,20" time="40000" pulse="true" tween="sine" easing="inout" condition="!String.IsEmpty(Window.Property(WCS.MyTV.Animation))">Conditional</animation>
        </control>
        
        <!-- Dynamic Dimming Overlay (uses property from Python) -->
        <control type="image">
            <left>0</left>
            <top>0</top>
            <width>1920</width>
            <height>1080</height>
            <texture colordiffuse="$INFO[Window.Property(WCS.MyTV.BackgroundDim)]">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.BackgroundDim))</visible>
        </control>
        
        <!-- Fallback Dimming when property not set -->
        <control type="image">
            <left>0</left>
            <top>0</top>
            <width>1920</width>
            <height>1080</height>
            <texture colordiffuse="80000000">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
            <visible>String.IsEmpty(Window.Property(WCS.MyTV.BackgroundDim))</visible>
        </control>
        
        <!-- Dark Gradient from Top (header readability) -->
        <control type="image">
            <left>0</left>
            <top>0</top>
            <width>1920</width>
            <height>400</height>
            <texture colordiffuse="D0000000">special://home/addons/plugin.video.milionar/resources/media/gradient_top_fade.png</texture>
            <visible>true</visible>
        </control>
        
        <!-- ==================================================================================== -->
        <!-- INFO LAYER (HEADER) -->
        <!-- ==================================================================================== -->
        <control type="group">
            <left>48</left>
            <top>35</top>
            <width>1285</width>
            <height>200</height>
            <animation effect="slide" start="-400,0" end="0,0" time="350" delay="100" tween="cubic" easing="out">WindowOpen</animation>
            <animation effect="slide" start="0,0" end="-400,0" time="250" tween="cubic" easing="in">WindowClose</animation>
            
            <!-- Title -->
            <control type="label">
                <width>1285</width>
                <height>70</height>
                <font>font60</font>
                <label>$INFO[Window.Property(WCS.AIChat.Title)]</label>
                <textcolor>E8E8E8FF</textcolor>
                <shadowcolor>black</shadowcolor>
            </control>
        </control>
        
        <!-- ==================================================================================== -->
        <!-- CLOCK / DATE DISPLAY (TOP RIGHT) -->
        <!-- ==================================================================================== -->
        <control type="group">
            <left>1472</left>
            <top>35</top>
            <width>400</width>
            <height>100</height>
            <animation effect="slide" start="400,0" end="0,0" time="400" delay="200" tween="cubic" easing="out">WindowOpen</animation>
            <animation effect="slide" start="0,0" end="400,0" time="250" tween="cubic" easing="in">WindowClose</animation>
            
            <!-- Time (large) -->
            <control type="label">
                <left>0</left>
                <top>0</top>
                <width>400</width>
                <height>55</height>
                <font>font60</font>
                <label>$INFO[System.Time(hh:mm)]</label>
                <textcolor>EEFFFFFF</textcolor>
                <shadowcolor>80000000</shadowcolor>
                <align>right</align>
            </control>
            
            <!-- Day name + Date -->
            <control type="label">
                <left>0</left>
                <top>70</top>
                <width>400</width>
                <height>30</height>
                <font>font13</font>
                <label>$INFO[System.Date]</label>
                <textcolor>99FFFFFF</textcolor>
                <align>right</align>
            </control>
        </control>

        <!-- ==================================================================================== -->
        <!-- EDITOR LAYER - FLAT STRUCTURE FOR PROPER NAVIGATION -->
        <!-- ==================================================================================== -->
        
        <!-- Channel Statistics Row -->
        <control type="label">
            <left>48</left>
            <top>115</top>
            <width>1000</width>
            <height>30</height>
            <font>font12</font>
            <label>$INFO[Window.Property(WCS.Channel.Stats)]</label>
            <textcolor>90FFFFFF</textcolor>
            <visible>!String.IsEmpty(Window.Property(WCS.Channel.Stats))</visible>
        </control>
        
        <!-- Editor Header / Channel Name (TV Mode) -->
        <control type="label">
            <left>48</left>
            <top>160</top>
            <width>1200</width>
            <height>50</height>
            <font>font30</font>
            <label>Obsah kanálu: $INFO[Container(2000).ListItem.Label]</label>
            <textcolor>E8E8E8FF</textcolor>
            <scroll>true</scroll>
            <visible>!String.IsEqual(Container(2000).ListItem.Property(is_create_button),true) + !String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
        </control>
        <!-- Editor Header / Cinema Name (Cinema Mode) -->
        <control type="label">
            <left>48</left>
            <top>160</top>
            <width>1200</width>
            <height>50</height>
            <font>font30</font>
            <label>Obsah kina: $INFO[Container(2000).ListItem.Label]</label>
            <textcolor>E8E8E8FF</textcolor>
            <scroll>true</scroll>
            <visible>!String.IsEqual(Container(2000).ListItem.Property(is_create_button),true) + String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
        </control>

        <!-- ==================================================================================== -->
        <!-- ACTION BUTTONS (TOP) - ID 9099 -->
        <!-- ==================================================================================== -->
        <control type="grouplist" id="9099">
             <left>1132</left>
             <top>160</top>
             <width>720</width>
             <height>60</height>
             <itemgap>20</itemgap>
             <orientation>horizontal</orientation>
             <align>right</align>
             <usecontrolcoords>true</usecontrolcoords>
             <onleft>noop</onleft>
             <onright>noop</onright>
             <visible>!String.IsEqual(Container(2000).ListItem.Property(is_create_button),true)</visible>
             <animation effect="fade" start="0" end="100" time="300" condition="Control.HasFocus(9004) | Control.HasFocus(9003)">Visible</animation>
             <animation effect="fade" start="100" end="50" time="300" condition="!Control.HasFocus(9004) + !Control.HasFocus(9003)">Hidden</animation>

             <!-- Play Broadcast -->
             <control type="button" id="9004">
                 <width>250</width>
                 <height>50</height>
                 <font>font24</font>
                 <label>$INFO[Window.Property(WCS.Button.Play)]</label>
                 <align>center</align>
                 <onup>noop</onup>
                 <ondown>9000</ondown>
                 <onleft>noop</onleft>
                 <onright>9003</onright>
                 <texturefocus border="25" colordiffuse="60FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturefocus>
                 <texturenofocus border="25" colordiffuse="25808080">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturenofocus>
             </control>



             <!-- Delete Channel -->
             <control type="button" id="9003">
                 <width>224</width>
                 <height>50</height>
                 <font>font24</font>
                 <label>$INFO[Window.Property(WCS.Button.Delete)]</label>
                 <align>center</align>
                 <onup>noop</onup>
                 <ondown>9000</ondown>
                 <onright>noop</onright>
                 <onleft>9004</onleft>
                 <texturefocus border="25" colordiffuse="FFEA0000">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturefocus>
                 <texturenofocus border="25" colordiffuse="25808080">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturenofocus>
             </control>
        </control>

        <!-- ==================================================================================== -->
        <!-- DELETE CONFIRMATION INLINE DIALOG -->
        <!-- ==================================================================================== -->
        <control type="group">
            <left>1132</left>
            <top>155</top>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.DeleteConfirm),true)</visible>
            <animation effect="slide" start="0,0" end="0,0" time="0">Visible</animation>
            <animation effect="fade" start="0" end="100" time="200">Visible</animation>
            <animation effect="fade" start="100" end="0" time="150">Hidden</animation>
            
            <!-- Background panel -->
            <control type="image">
                <left>0</left>
                <top>0</top>
                <width>720</width>
                <height>60</height>
                <texture border="25" colordiffuse="FF1a2535">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texture>
            </control>
            
            <!-- Warning text -->
            <control type="label">
                <left>20</left>
                <top>0</top>
                <width>480</width>
                <height>60</height>
                <font>font24</font>
                <label>$INFO[Window.Property(WCS.Button.DeleteConfirm)]</label>
                <textcolor>white</textcolor>
                <align>left</align>
                <aligny>center</aligny>
            </control>
            
            <!-- Confirm button -->
            <control type="button" id="9006">
                <left>500</left>
                <top>5</top>
                <width>200</width>
                <height>50</height>
                <font>font24</font>
                <label>Potvrdit</label>
                <align>center</align>
                <aligny>center</aligny>
                <onleft>9006</onleft>
                <onright>9006</onright>
                <onup>9006</onup>
                <ondown>9006</ondown>
                <texturefocus border="25" colordiffuse="CC44AA44">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturefocus>
                <texturenofocus border="25" colordiffuse="40FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturenofocus>
            </control>
        </control>

        <!-- ==================================================================================== -->
        <!-- SERIES GRID (LEFT) - ID 9100 -->
        <!-- ==================================================================================== -->
        <control type="panel" id="9100">
            <left>90</left>
            <top>240</top>
            <width>880</width>
            <height>370</height>
            <onup>noop</onup>
            <ondown>2000</ondown>
            <onleft>noop</onleft>
            <onright>9000</onright>
            <viewtype label="icon">icon</viewtype>
            <preloaditems>2</preloaditems>
            <visible>!String.IsEqual(Container(2000).ListItem.Property(is_create_button),true)</visible>
            <animation effect="fade" start="0" end="100" time="300" condition="Control.HasFocus(9100)">Visible</animation>
            <animation effect="fade" start="100" end="50" time="300" condition="!Control.HasFocus(9100)">Hidden</animation>
            
            <itemlayout height="180" width="120">
                 <!-- Card Background -->
                 <control type="image">
                    <left>10</left>
                    <top>10</top>
                    <width>110</width>
                    <height>165</height>
                    <texture fallback="special://home/addons/plugin.video.milionar/resources/media/placeholder_tv_card.jpg" diffuse="special://home/addons/plugin.video.milionar/resources/media/card_mask.png">$INFO[ListItem.Art(poster)]</texture>
                    <aspectratio>stretch</aspectratio>
                 </control>
                 <!-- Checkmark overlay -->
                 <control type="image">
                    <right>5</right>
                    <bottom>15</bottom>
                    <width>30</width>
                    <height>30</height>
                    <texture>special://home/addons/plugin.video.milionar/resources/media/checkmark.png</texture>
                    <visible>String.IsEqual(ListItem.Property(IsSelected),true)</visible>
                 </control>
            </itemlayout>

            <focusedlayout height="180" width="120">
                <control type="image">
                    <left>5</left>
                    <top>5</top>
                    <width>120</width>
                    <height>180</height>
                     <texture fallback="special://home/addons/plugin.video.milionar/resources/media/placeholder_tv_card.jpg" diffuse="special://home/addons/plugin.video.milionar/resources/media/card_mask.png">$INFO[ListItem.Art(poster)]</texture>
                    <aspectratio>stretch</aspectratio>
                    <animation effect="zoom" start="100" end="110" center="auto" time="200">Focus</animation>
                </control>
                <!-- Focus Border -->
                <control type="image">
                    <left>0</left>
                    <top>0</top>
                    <width>130</width>
                    <height>190</height>
                    <texture colordiffuse="FFCCCCCC">special://home/addons/plugin.video.milionar/resources/media/card_border_focus.png</texture>
                    <aspectratio>stretch</aspectratio>
                    <animation effect="zoom" start="100" end="110" center="auto" time="200">Focus</animation>
                </control>
            </focusedlayout>
        </control>

        <!-- ==================================================================================== -->
        <!-- PROGRAM LIST (RIGHT) - ID 9000 -->
        <!-- ==================================================================================== -->
        <control type="list" id="9000">
            <left>1040</left>
            <top>240</top>
            <width>820</width>
            <height>800</height>
            <onup>9004</onup>
            <ondown>noop</ondown>
            <onleft>9100</onleft>
            <onright>noop</onright>
            <pagecontrol>9010</pagecontrol>
            <orientation>vertical</orientation>
            <scrolltime tween="cubic" easing="out">300</scrolltime>
            <visible>!String.IsEqual(Container(2000).ListItem.Property(is_create_button),true) + !String.IsEqual(Window.Property(WCS.MyTV.PlaySelection),true)</visible>
            
            <!-- ITEMLAYOUT - 130px karta s episode still, logem jako overlay, nazvy a plotem -->
            <itemlayout height="135">
                <!-- Episode Still (leva cast) -->
                <control type="image">
                    <left>6</left>
                    <top>10</top>
                    <width>200</width>
                    <height>113</height>
                    <texture fallback="special://home/addons/plugin.video.milionar/resources/media/placeholder_tv_card.jpg" diffuse="special://home/addons/plugin.video.milionar/resources/media/still_mask_rounded.png">$INFO[ListItem.Art(thumb)]</texture>
                    <aspectratio>scale</aspectratio>
                </control>

                
                <!-- Logo serialu jako overlay dole na still (pokud existuje) -->
                <control type="image">
                    <left>10</left>
                    <top>88</top>
                    <width>190</width>
                    <height>32</height>
                    <texture>$INFO[ListItem.Property(series_logo)]</texture>
                    <aspectratio aligny="bottom">keep</aspectratio>
                    <visible>!String.IsEmpty(ListItem.Property(series_logo))</visible>
                </control>
                
                <!-- Watched indicator (text label) -->
                <control type="label">
                    <left>6</left>
                    <top>95</top>
                    <width>200</width>
                    <height>25</height>
                    <font>font10</font>
                    <label>watched</label>
                    <textcolor>FFFFFFFF</textcolor>
                    <align>right</align>
                    <visible>String.IsEqual(ListItem.Property(watched),true)</visible>
                </control>
                
                <!-- Název seriálu (vždy zobrazen nahoře) -->
                <control type="label">
                    <left>220</left>
                    <top>5</top>
                    <width>480</width>
                    <height>30</height>
                    <font>font32</font>
                    <label>$INFO[ListItem.Label]</label>
                    <textcolor>EEFFFFFF</textcolor>
                    <aligny>center</aligny>
                </control>
                
                <!-- Runtime (vpravo nahore) -->
                <control type="label">
                    <left>700</left>
                    <top>5</top>
                    <width>100</width>
                    <height>30</height>
                    <font>font12</font>
                    <label>$INFO[ListItem.Label2]</label>
                    <textcolor>80FFFFFF</textcolor>
                    <align>right</align>
                    <aligny>center</aligny>
                </control>
                
                <!-- Číslo epizody (S01E03) -->
                <control type="label">
                    <left>220</left>
                    <top>34</top>
                    <width>200</width>
                    <height>22</height>
                    <font>font12</font>
                    <label>$INFO[ListItem.Property(ep_code)]</label>
                    <textcolor>80AACCFF</textcolor>
                </control>
                
                <!-- Název epizody -->
                <control type="label">
                    <left>220</left>
                    <top>60</top>
                    <width>580</width>
                    <height>30</height>
                    <font>font13</font>
                    <label>$INFO[ListItem.Property(episode_title)]</label>
                    <textcolor>BBFFFFFF</textcolor>
                </control>
                
                <!-- Plot (zkraceny) -->
                <control type="label">
                    <left>220</left>
                    <top>95</top>
                    <width>580</width>
                    <height>35</height>
                    <font>font12</font>
                    <label>$INFO[ListItem.Property(plot_short)]</label>
                    <textcolor>60FFFFFF</textcolor>
                </control>
            </itemlayout>
            
            <!-- FOCUSEDLAYOUT - s glow efektem a zvyraznenim -->
            <focusedlayout height="135">
                <!-- Focus glow/background -->
                <control type="image">
                    <left>0</left>
                    <top>3</top>
                    <width>810</width>
                    <height>127</height>
                    <texture border="20" colordiffuse="50FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texture>
                    <visible>Control.HasFocus(9000)</visible>
                </control>
                
                <!-- Episode Still (leva cast) -->
                <control type="image">
                    <left>6</left>
                    <top>10</top>
                    <width>200</width>
                    <height>113</height>
                    <texture fallback="special://home/addons/plugin.video.milionar/resources/media/placeholder_tv_card.jpg" diffuse="special://home/addons/plugin.video.milionar/resources/media/still_mask_rounded.png">$INFO[ListItem.Art(thumb)]</texture>
                    <aspectratio>scale</aspectratio>
                    <animation effect="zoom" start="100" end="100" center="auto" time="150">Focus</animation>
                </control>

                
                <!-- Logo seriálu jako overlay dole na still (pokud existuje) -->
                <control type="image">
                    <left>10</left>
                    <top>88</top>
                    <width>190</width>
                    <height>32</height>
                    <texture>$INFO[ListItem.Property(series_logo)]</texture>
                    <aspectratio aligny="bottom">keep</aspectratio>
                    <visible>!String.IsEmpty(ListItem.Property(series_logo))</visible>
                </control>
                
                <!-- Watched indicator (text label) -->
                <control type="label">
                    <left>6</left>
                    <top>95</top>
                    <width>200</width>
                    <height>25</height>
                    <font>font10</font>
                    <label>watched</label>
                    <textcolor>FFFFFFFF</textcolor>
                    <align>right</align>
                    <visible>String.IsEqual(ListItem.Property(watched),true)</visible>
                </control>
                
                <!-- Název seriálu (vždy zobrazen nahoře) - bílá při focusu -->
                <control type="label">
                    <left>220</left>
                    <top>5</top>
                    <width>480</width>
                    <height>30</height>
                    <font>font32</font>
                    <label>$INFO[ListItem.Label]</label>
                    <textcolor>white</textcolor>
                    <aligny>center</aligny>
                </control>
                
                <!-- Runtime (vpravo nahore) -->
                <control type="label">
                    <left>700</left>
                    <top>5</top>
                    <width>100</width>
                    <height>30</height>
                    <font>font12</font>
                    <label>$INFO[ListItem.Label2]</label>
                    <textcolor>white</textcolor>
                    <align>right</align>
                    <aligny>center</aligny>
                </control>
                
                <!-- Číslo epizody (S01E03) -->
                <control type="label">
                    <left>220</left>
                    <top>34</top>
                    <width>200</width>
                    <height>22</height>
                    <font>font12</font>
                    <label>$INFO[ListItem.Property(ep_code)]</label>
                    <textcolor>CCAACCFF</textcolor>
                </control>
                
                <!-- Název epizody - bílá při focusu -->
                <control type="label">
                    <left>220</left>
                    <top>60</top>
                    <width>580</width>
                    <height>30</height>
                    <font>font13</font>
                    <label>$INFO[ListItem.Property(episode_title)]</label>
                    <textcolor>white</textcolor>
                </control>
                
                <!-- Plot (plný text s autoscrollem) - světlejší při focusu -->
                <!-- Plot (plný text - klasický label se scrollem) -->
                <control type="label">
                    <left>220</left>
                    <top>95</top>
                    <width>580</width>
                    <height>35</height>
                    <font>font12</font>
                    <label>$INFO[ListItem.Property(plot)]</label>
                    <textcolor>CCFFFFFF</textcolor>
                    <scroll>true</scroll>
                    <scrollspeed>50</scrollspeed>
                    <scrollsuffix> • </scrollsuffix>
                </control>
            </focusedlayout>
        </control>

        <!-- Scrollbar for Program List 9000 -->
        <control type="scrollbar" id="9010">
            <left>1865</left>
            <top>240</top>
            <width>12</width>
            <height>750</height>
            <texturesliderbackground border="6" colordiffuse="15FFFFFF">special://home/addons/plugin.video.milionar/resources/media/scrollbar_rounded.png</texturesliderbackground>
            <texturesliderbar border="6" colordiffuse="50FFFFFF">special://home/addons/plugin.video.milionar/resources/media/scrollbar_rounded.png</texturesliderbar>
            <texturesliderbarfocus border="6" colordiffuse="FFFFFFFF">special://home/addons/plugin.video.milionar/resources/media/scrollbar_rounded.png</texturesliderbarfocus>
            <textureslidernib colordiffuse="00FFFFFF"></textureslidernib>
            <textureslidernibfocus colordiffuse="00FFFFFF"></textureslidernibfocus>
            <showonepage>false</showonepage>
            <orientation>vertical</orientation>
            <visible>!String.IsEqual(Container(2000).ListItem.Property(is_create_button),true) + !String.IsEqual(Window.Property(WCS.MyTV.PlaySelection),true)</visible>
            <animation effect="fade" start="0" end="100" time="300" condition="Control.HasFocus(9010) | Control.HasFocus(9000)">Visible</animation>
            <animation effect="fade" start="100" end="0" time="300" condition="!Control.HasFocus(9010) + !Control.HasFocus(9000)">Hidden</animation>
        </control>
        <!-- ==================================================================================== -->
        <!-- PLAY SELECTION DIALOG (Full Area Overlay) -->
        <!-- ==================================================================================== -->
        <control type="group">
            <left>1040</left>
            <top>240</top>
            <visible>String.IsEqual(Window.Property(WCS.MyTV.PlaySelection),true)</visible>
            <animation effect="fade" start="0" end="100" time="200">Visible</animation>
            <animation effect="fade" start="100" end="0" time="150">Hidden</animation>
            
            <!-- Fanart Background (FIRST - behind everything) -->
            <control type="image">
                <left>0</left>
                <top>0</top>
                <width>820</width>
                <height>350</height>
                <texture diffuse="special://home/addons/plugin.video.milionar/resources/media/still_mask_rounded.png" fallback="$INFO[Window.Property(WCS.PlaySelect.Fanart)]">$INFO[Window.Property(WCS.PlaySelect.Still)]</texture>
                <aspectratio>scale</aspectratio>
            </control>
            
            <!-- Semi-transparent Dark Background with Rounded Corners (on top of fanart) -->
            <control type="image">
                <left>0</left>
                <top>0</top>
                <width>820</width>
                <height>800</height>
                <texture border="40" colordiffuse="80101520">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texture>
            </control>
            
            <!-- Poster (Left Side) -->
            <control type="image">
                <left>30</left>
                <top>50</top>
                <width>180</width>
                <height>270</height>
                <texture diffuse="special://home/addons/plugin.video.milionar/resources/media/poster_mask_rounded.png" fallback="special://home/addons/plugin.video.milionar/resources/media/placeholder_poster.png">$INFO[Window.Property(WCS.PlaySelect.Poster)]</texture>
                <aspectratio>scale</aspectratio>
            </control>
            
            <!-- Text Overlay Background (for readability) -->
            <control type="image">
                <left>220</left>
                <top>50</top>
                <width>580</width>
                <height>270</height>
                <texture border="15" colordiffuse="90000000">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texture>
            </control>
            
            <!-- Episode Info (Right of Poster) -->
            <control type="group">
                <left>235</left>
                <top>60</top>
                
                <!-- Series Name -->
                <control type="label">
                    <left>0</left>
                    <top>0</top>
                    <width>550</width>
                    <height>45</height>
                    <font>font37</font>
                    <label>$INFO[Window.Property(WCS.PlaySelect.SeriesName)]</label>
                    <textcolor>white</textcolor>
                </control>
                
                <!-- Episode Title Only -->
                <control type="label">
                    <left>0</left>
                    <top>38</top>
                    <width>550</width>
                    <height>30</height>
                    <font>font14</font>
                    <label>$INFO[Window.Property(WCS.PlaySelect.EpTitle)]</label>
                    <textcolor>FFAACCFF</textcolor>
                </control>
                
                <!-- Year / Genre / Episode Code -->
                <control type="label">
                    <left>0</left>
                    <top>77</top>
                    <width>550</width>
                    <height>25</height>
                    <font>font12</font>
                    <label>$INFO[Window.Property(WCS.PlaySelect.EpCode)]  |  $INFO[Window.Property(WCS.PlaySelect.Year)]  |  $INFO[Window.Property(WCS.PlaySelect.Genre)]</label>
                    <textcolor>99FFFFFF</textcolor>
                </control>
                
                <!-- Rating (Yellow) -->
                <control type="label">
                    <left>0</left>
                    <top>107</top>
                    <width>550</width>
                    <height>25</height>
                    <font>font12</font>
                    <label>Hodnocení: $INFO[Window.Property(WCS.PlaySelect.Rating)]</label>
                    <textcolor>FFFFAA00</textcolor>
                </control>
                
                <!-- Plot -->
                <control type="textbox">
                    <left>0</left>
                    <top>142</top>
                    <width>550</width>
                    <height>105</height>
                    <font>font12</font>
                    <label>$INFO[Window.Property(WCS.PlaySelect.Plot)]</label>
                    <textcolor>CCFFFFFF</textcolor>
                </control>
            </control>
            
            <!-- Buttons Section -->
            <control type="group">
                <left>30</left>
                <top>420</top>
                
                <!-- Buttons Grouplist (no section title) -->
                <control type="grouplist">
                    <left>0</left>
                    <top>0</top>
                    <width>760</width>
                    <height>400</height>
                    <itemgap>15</itemgap>
                    <orientation>vertical</orientation>
                    <onleft>noop</onleft>
                    <onright>noop</onright>
                    
                    <!-- Play Channel Button -->
                    <control type="group">
                        <width>760</width>
                        <height>120</height>
                        
                        <control type="button" id="9020">
                            <left>0</left>
                            <top>0</top>
                            <width>760</width>
                            <height>120</height>
                            <texturefocus border="20" colordiffuse="DD3377CC">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturefocus>
                            <texturenofocus border="20" colordiffuse="40FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturenofocus>
                            <label> </label>
                            <onup>9022</onup>
                            <ondown>9021</ondown>
                        </control>
                        
                        <control type="label">
                            <left>0</left>
                            <top>10</top>
                            <width>760</width>
                            <height>35</height>
                            <font>font14_bold</font>
                            <label>Spustit kanál (mix seriálů)</label>
                            <textcolor>white</textcolor>
                            <align>center</align>
                            <aligny>center</aligny>
                        </control>
                        
                        <control type="label">
                            <left>0</left>
                            <top>45</top>
                            <width>760</width>
                            <height>50</height>
                            <font>font12</font>
                            <label>Pokračuje od této epizody a přehrává mix všech seriálů v kanálu. Ideální pro sledování namixovaného programu.</label>
                            <textcolor>77FFFFFF</textcolor>
                            <align>center</align>
                            <wrapmultiline>true</wrapmultiline>
                        </control>
                    </control>
                    
                    <!-- Play Series Only Button -->
                    <control type="group">
                        <width>760</width>
                        <height>120</height>
                        
                        <control type="button" id="9021">
                            <left>0</left>
                            <top>0</top>
                            <width>760</width>
                            <height>120</height>
                            <texturefocus border="20" colordiffuse="DD44AA44">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturefocus>
                            <texturenofocus border="20" colordiffuse="40FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturenofocus>
                            <label> </label>
                            <onup>9020</onup>
                            <ondown>9022</ondown>
                        </control>
                        
                        <control type="label">
                            <left>0</left>
                            <top>10</top>
                            <width>760</width>
                            <height>35</height>
                            <font>font14_bold</font>
                            <label>Spustit jen '$INFO[Window.Property(WCS.PlaySelect.SeriesName)]'</label>
                            <textcolor>white</textcolor>
                            <align>center</align>
                            <aligny>center</aligny>
                        </control>
                        
                        <control type="label">
                            <left>0</left>
                            <top>45</top>
                            <width>760</width>
                            <height>50</height>
                            <font>font12</font>
                            <label>Přehrává pouze epizody tohoto seriálu od vybrané epizody. Ideální pro binge-watching jednoho seriálu.</label>
                            <textcolor>77FFFFFF</textcolor>
                            <align>center</align>
                            <wrapmultiline>true</wrapmultiline>
                        </control>
                    </control>
                    
                    <!-- Cancel Button -->
                    <control type="group">
                        <width>760</width>
                        <height>50</height>
                        
                        <control type="button" id="9022">
                            <left>0</left>
                            <top>0</top>
                            <width>760</width>
                            <height>50</height>
                            <font>font12</font>
                            <label>Zrušit</label>
                            <align>center</align>
                            <aligny>center</aligny>
                            <texturefocus border="15" colordiffuse="CCFF4444">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturefocus>
                            <texturenofocus border="15" colordiffuse="30FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturenofocus>
                            <onup>9021</onup>
                            <ondown>9020</ondown>
                        </control>
                    </control>
                </control>
            </control>
        </control>


        <!-- Create Channel Placeholder (TV Mode) -->
        <control type="label">
            <left>90</left>
            <top>350</top>
            <width>1750</width>
            <height>100</height>
            <font>font60</font>
            <label>Vytvořit nový kanál</label>
            <textcolor>white</textcolor>
            <align>center</align>
            <aligny>center</aligny>
            <visible>String.IsEqual(Container(2000).ListItem.Property(is_create_button),true) + !String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
        </control>
        <!-- Create Cinema Placeholder (Cinema Mode) -->
        <control type="label">
            <left>90</left>
            <top>350</top>
            <width>1750</width>
            <height>100</height>
            <font>font60</font>
            <label>Vytvořit nové kino</label>
            <textcolor>white</textcolor>
            <align>center</align>
            <aligny>center</aligny>
            <visible>String.IsEqual(Container(2000).ListItem.Property(is_create_button),true) + String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
        </control>
        
        <!-- ==================================================================================== -->
        <!-- CONTENT LAYER (Bottom List) -->
        <!-- ==================================================================================== -->
        
        <control type="list" id="2000">

            <left>30</left>
            <top>650</top>
            <width>1012</width>
            <height>420</height>
            <onup>9100</onup>
            <ondown>noop</ondown>
            <onleft>noop</onleft>
            <onright>noop</onright>
            <viewtype label="icon">icon</viewtype>
            <orientation>horizontal</orientation>
            <scrolltime tween="cubic" easing="out">400</scrolltime>
            <preloaditems>2</preloaditems>
            <!-- Slide animace - vyjede zdola -->
            <animation effect="slide" start="0,450" end="0,0" time="400" delay="200" tween="cubic" easing="out">WindowOpen</animation>
            <animation effect="slide" start="0,0" end="0,450" time="300" tween="cubic" easing="in">WindowClose</animation>
            
            <itemlayout height="418" width="253">
                <control type="image">
                    <left>22</left>
                    <top>33</top>
                    <width>209</width>
                    <height>314</height>
                    <texture fallback="special://home/addons/plugin.video.milionar/resources/media/placeholder_tv_card.jpg" diffuse="special://home/addons/plugin.video.milionar/resources/media/card_mask.png">$INFO[ListItem.Art(poster)]</texture>
                    <aspectratio>stretch</aspectratio>
                </control>
            </itemlayout>

            <focusedlayout height="418" width="253">
                <control type="image">
                    <left>22</left>
                    <top>33</top>
                    <width>209</width>
                    <height>314</height>
                    <texture fallback="special://home/addons/plugin.video.milionar/resources/media/placeholder_tv_card.jpg" diffuse="special://home/addons/plugin.video.milionar/resources/media/card_mask.png">$INFO[ListItem.Art(poster)]</texture>
                    <aspectratio>stretch</aspectratio>
                    <animation effect="zoom" start="100" end="120" center="auto" time="200">Focus</animation>
                </control>
                <!-- Focus Border -->
                <control type="image">
                    <left>14</left>
                    <top>25</top>
                    <width>224</width>
                    <height>329</height>
                    <texture colordiffuse="FFCCCCCC">special://home/addons/plugin.video.milionar/resources/media/card_border_focus.png</texture>
                    <aspectratio>stretch</aspectratio>
                    <animation effect="zoom" start="100" end="120" center="auto" time="200">Focus</animation>
                </control>
            </focusedlayout>
        </control>

        <!-- ==================================================================================== -->
        <!-- NAVIGATION SIDEBAR (Left Side) -->
        <!-- ==================================================================================== -->
        <control type="group" id="7000">
            <visible>Control.HasFocus(7100) | Control.HasFocus(7200) | !String.IsEmpty(Window.Property(WCS.NavSidebar.Visible))</visible>
            <animation effect="slide" start="-450,0" end="0,0" time="300" tween="cubic" easing="out" condition="String.IsEmpty(Window.Property(WCS.NavSidebar.NoAnimation))">Visible</animation>
            <animation effect="slide" end="-450,0" start="0,0" time="300" tween="cubic" easing="in" condition="String.IsEmpty(Window.Property(WCS.NavSidebar.NoAnimation))">Hidden</animation>
            
            <!-- Background Panel -->
            <control type="image">
                <left>0</left>
                <top>0</top>
                <width>450</width>
                <height>1080</height>
                <texture colordiffuse="F2101010">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
            </control>
            
            <!-- Gradient Edge (Right side of sidebar) -->
            <control type="image">
                <left>440</left>
                <top>0</top>
                <width>30</width>
                <height>1080</height>
                <texture colordiffuse="80000000">special://home/addons/plugin.video.milionar/resources/media/gradient_right.png</texture>
            </control>
            
            <!-- Header Title -->
            <control type="group">
                <left>0</left><top>0</top><width>450</width><height>150</height>
                <control type="image">
                    <left>0</left><top>0</top><width>450</width><height>150</height>
                    <texture colordiffuse="FF101010">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                </control>
                <control type="image">
                    <left>69</left><top>39</top><width>72</width><height>72</height>
                    <aspectratio>keep</aspectratio>
                    <texture colordiffuse="$INFO[Window(Home).Property(milionar.logo.tint)]">special://home/addons/plugin.video.milionar/resources/media/brand/milionar-mark.png</texture>
                </control>
                <control type="label">
                    <left>153</left><top>31</top><width>228</width><height>88</height>
                    <font>font32_milionar_brand</font><aligny>center</aligny>
                    <textcolor>$INFO[Window(Home).Property(milionar.logo.wordmark)]</textcolor>
                    <label>MILIONÁŘ</label>
                    <visible>Skin.HasSetting(MilionarDefaultsV1)</visible>
                </control>
                <control type="label">
                    <left>153</left><top>31</top><width>228</width><height>88</height>
                    <font>font32_title</font><aligny>center</aligny>
                    <textcolor>$INFO[Window(Home).Property(milionar.logo.wordmark)]</textcolor>
                    <label>MILIONÁŘ</label>
                    <visible>!Skin.HasSetting(MilionarDefaultsV1)</visible>
                </control>
            </control>

            <!-- Horizontal Icon Bar -->
            <control type="list" id="7200">
                <left>30</left>
                <top>155</top>
                <width>390</width>
                <height>90</height>
                <onleft>noop</onleft>
                <onright>2000</onright>
                <onup>noop</onup>
                <ondown>7100</ondown>
                <orientation>horizontal</orientation>
                
                <itemlayout width="130" height="90">
                    <control type="image">
                        <left>30</left>
                        <top>10</top>
                        <width>70</width>
                        <height>70</height>
                        <texture>$INFO[ListItem.Icon]</texture>
                        <colordiffuse>grey</colordiffuse>
                        <aspectratio>keep</aspectratio>
                    </control>
                </itemlayout>
                
                <focusedlayout width="130" height="90">
                    <control type="image">
                        <left>15</left>
                        <top>5</top>
                        <width>100</width>
                        <height>80</height>
                        <texture colordiffuse="FF0090EA">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                        <visible>Control.HasFocus(7200)</visible>
                    </control>
                    <control type="image">
                        <left>30</left>
                        <top>10</top>
                        <width>70</width>
                        <height>70</height>
                        <texture>$INFO[ListItem.Icon]</texture>
                        <colordiffuse>white</colordiffuse>
                        <aspectratio>keep</aspectratio>
                        <visible>Control.HasFocus(7200)</visible>
                    </control>
                    <control type="image">
                        <left>30</left>
                        <top>10</top>
                        <width>70</width>
                        <height>70</height>
                        <texture>$INFO[ListItem.Icon]</texture>
                        <colordiffuse>grey</colordiffuse>
                        <aspectratio>keep</aspectratio>
                        <visible>!Control.HasFocus(7200)</visible>
                    </control>
                </focusedlayout>
            </control>
            
            <!-- Navigation Menu List -->
            <control type="list" id="7100">
                <left>0</left>
                <top>250</top>
                <width>450</width>
                <height>830</height>

                <orientation>vertical</orientation>
                <scrolltime tween="cubic" easing="out">200</scrolltime>
                
                <itemlayout height="100" width="450">
                    <control type="group">
                        <control type="image">
                            <left>30</left>
                            <top>15</top>
                            <width>70</width>
                            <height>70</height>
                            <texture>$INFO[ListItem.Icon]</texture>
                            <aspectratio>keep</aspectratio>
                            <colordiffuse>grey</colordiffuse>
                        </control>
                        <control type="label">
                            <left>120</left>
                            <top>0</top>
                            <width>310</width>
                            <height>100</height>
                            <font>font30</font>
                            <label>$INFO[ListItem.Label]</label>
                            <textcolor>white</textcolor>
                            <aligny>center</aligny>
                        </control>
                    </control>
                </itemlayout>
                
                <focusedlayout height="100" width="450">
                    <control type="group">
                        <control type="image">
                            <left>0</left>
                            <top>0</top>
                            <width>450</width>
                            <height>100</height>
                            <texture colordiffuse="FF0090EA">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                            <visible>Control.HasFocus(7100)</visible>
                        </control>
                        <control type="image">
                            <left>0</left>
                            <top>0</top>
                            <width>5</width>
                            <height>100</height>
                            <texture colordiffuse="FFFFFFFF">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                            <visible>Control.HasFocus(7100)</visible>
                        </control>
                        <control type="image">
                            <left>30</left>
                            <top>15</top>
                            <width>70</width>
                            <height>70</height>
                            <texture>$INFO[ListItem.Icon]</texture>
                            <aspectratio>keep</aspectratio>
                            <colordiffuse>white</colordiffuse>
                            <visible>Control.HasFocus(7100)</visible>
                        </control>
                        <control type="image">
                            <left>30</left>
                            <top>15</top>
                            <width>70</width>
                            <height>70</height>
                            <texture>$INFO[ListItem.Icon]</texture>
                            <aspectratio>keep</aspectratio>
                            <colordiffuse>grey</colordiffuse>
                            <visible>!Control.HasFocus(7100)</visible>
                        </control>
                        <control type="label">
                            <left>120</left>
                            <top>0</top>
                            <width>310</width>
                            <height>100</height>
                            <font>font30</font>
                            <label>$INFO[ListItem.Label]</label>
                            <textcolor>white</textcolor>
                            <shadowcolor>black</shadowcolor>
                            <aligny>center</aligny>
                            <visible>Control.HasFocus(7100)</visible>
                        </control>
                        <control type="label">
                            <left>120</left>
                            <top>0</top>
                            <width>310</width>
                            <height>100</height>
                            <font>font30</font>
                            <label>$INFO[ListItem.Label]</label>
                            <textcolor>grey</textcolor>
                            <aligny>center</aligny>
                            <visible>!Control.HasFocus(7100)</visible>
                        </control>
                    </control>
                </focusedlayout>
            </control>
        </control>
        
        <!-- Subtle Hint to open nav sidebar if hidden (Left Edge) -->
        <control type="group">
            <visible>String.IsEmpty(Window.Property(WCS.NavSidebar.Visible)) + !Control.HasFocus(7100)</visible>
            <left>0</left>
            <top>500</top>
            <control type="image">
                 <width>50</width>
                 <height>100</height>
                 <texture>common/arrow_right.png</texture>
                 <colordiffuse>40FFFFFF</colordiffuse>
            </control>
        </control>

        <!-- ==================================================================================== -->
        <!-- CHAT OVERLAY LAYER (Top Right/Float) - Copied from DialogAIChatRecommendation.xml -->
        <!-- ==================================================================================== -->
        <!-- Main Chat Group - Visible only when interacting with chat or toggled -->
        <control type="group" id="5000">
            <!-- Visibility Logic: Visible if Chat items focused OR Property WCS.AIChat.Visible is true -->
            <visible>Control.HasFocus(4000) | Control.HasFocus(3000) | Control.HasFocus(3001) | !String.IsEmpty(Window.Property(WCS.AIChat.Visible))</visible>
            <animation effect="slide" start="500,0" end="0,0" time="300" tween="cubic" easing="out">Visible</animation>
            <animation effect="slide" end="500,0" start="0,0" time="300" tween="cubic" easing="in">Hidden</animation>

            <!-- Background Panel for Chat -->
            <control type="image">
                <left>1320</left> <!-- Right side panel -->
                <top>0</top>
                <width>600</width>
                <height>1080</height>
                <texture colordiffuse="F2101010">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
            </control>
            
            <control type="label">
                <left>1350</left>
                <top>40</top>
                <width>540</width>
                <height>40</height>
                <font>font30_title</font>
                <label>AI Asistent</label>
                <textcolor>button_focus</textcolor>
            </control>
            
            <!-- Thinking Indicator (Visible when AI is working) -->
            <control type="group" id="5001">
                <left>1350</left>
                <top>72</top>
                <width>540</width>
                <height>20</height>
                
                <control type="label">
                     <left>0</left>
                     <width>300</width>
                     <height>20</height>
                     <font>font12</font>
                     <label>$INFO[Window.Property(WCS.AIChat.StatusText)]</label>
                     <textcolor>grey</textcolor>
                     <align>left</align>
                </control>
                
                <control type="label">
                     <left>0</left>
                     <width>510</width>
                     <height>20</height>
                     <font>font12</font>
                     <label>$INFO[Window.Property(WCS.AIChat.Timer)]</label>
                     <textcolor>button_focus</textcolor>
                     <align>right</align>
                </control>
            </control>
            
            <!-- Chat History -->
            <control type="textbox" id="1000">
                <left>1350</left>
                <top>115</top>
                <width>510</width>
                <height>385</height>
                <font>font13</font>
                <textcolor>white</textcolor>
                <pagecontrol>1001</pagecontrol>
                <autoscroll>false</autoscroll>
            </control>

            <!-- Focusable Transparent Button over History (Trigger Debug) -->
            <control type="button" id="1002">
                <left>1350</left>
                <top>115</top>
                <width>510</width>
                <height>385</height>
                <texturefocus border="25" colordiffuse="40FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturefocus>
                <texturenofocus></texturenofocus>
                <onleft>2000</onleft>
                <onright>1001</onright>
                <ondown>4000</ondown>
                <onup>noop</onup>
                <visible>Control.IsVisible(5000)</visible>
            </control>

            <!-- Scrollbar -->
            <control type="scrollbar" id="1001">
                <left>1870</left>
                <top>115</top>
                <width>20</width>
                <height>400</height>
                <onleft>1002</onleft>
                <ondown>4000</ondown>
                <texturesliderbackground border="2" colordiffuse="10FFFFFF">special://home/addons/plugin.video.milionar/resources/media/white.png</texturesliderbackground>
                <texturesliderbar border="2" colordiffuse="60FFFFFF">special://home/addons/plugin.video.milionar/resources/media/white.png</texturesliderbar>
                <texturesliderbarfocus border="2" colordiffuse="FFFFFFFF">special://home/addons/plugin.video.milionar/resources/media/white.png</texturesliderbarfocus>
                <textureslidernib colordiffuse="00FFFFFF"></textureslidernib>
                <textureslidernibfocus colordiffuse="00FFFFFF"></textureslidernibfocus>
                <showonepage>false</showonepage>
                <orientation>vertical</orientation>
            </control>
            
            <!-- Quick Options / Buttons -->
            <control type="list" id="4000">
                <visible>String.IsEmpty(Window.Property(WCS.AIChat.IsLoadingButtons))</visible>
                <animation effect="slide" end="-100,0" time="200" tween="back" easing="in">Hidden</animation>
                <animation effect="fade" start="100" end="0" time="200">Hidden</animation>
                <animation effect="slide" start="100,0" end="0,0" time="300" tween="cubic" easing="out">Visible</animation>
                <animation effect="fade" start="0" end="100" time="300">Visible</animation>

                <left>1350</left>
                <top>530</top>
                <width>540</width>
                <height>450</height>
                <onup>4001</onup> <!-- Safe close via hidden button -->
                <ondown>3000</ondown> <!-- Down to Input Field -->
                <onleft>2000</onleft> <!-- Left to content -->
                <itemlayout height="50" width="540">
                    <control type="label">
                        <left>10</left>
                        <label>* $INFO[ListItem.Label]</label>
                        <textcolor>grey</textcolor>
                    </control>
                </itemlayout>
                <focusedlayout height="50" width="540">
                    <control type="image">
                        <width>540</width>
                        <height>50</height>
                         <texture border="20" colordiffuse="20FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texture>
                    </control>
                     <control type="label">
                        <left>10</left>
                        <label>* $INFO[ListItem.Label]</label>
                        <textcolor>white</textcolor>
                    </control>
                </focusedlayout>
            </control>

            <!-- Hidden Button for Safe Sidebar Close (UP Action) -->
            <control type="button" id="4001">
                <left>-100</left>
                <top>-100</top>
                <width>1</width>
                <height>1</height>
                <onup>noop</onup>
                <ondown>4000</ondown>
                <onleft>2000</onleft>
                <onright>noop</onright>
            </control>
            
            <!-- Matrix Loading Group (Visible when processing buttons) -->
            <control type="group" id="5500">
                <visible>!String.IsEmpty(Window.Property(WCS.AIChat.IsLoadingButtons))</visible>
                <animation effect="zoom" start="90" end="100" center="auto" time="200">Visible</animation>
                <animation effect="fade" start="0" end="100" time="200">Visible</animation>
                <left>1350</left>
                <top>530</top>
                <width>540</width>
                <height>450</height>
                
                <!-- Glitch Text (Dissolving Button) -->
                <control type="label">
                    <left>0</left>
                    <top>150</top>
                    <width>540</width>
                    <height>50</height>
                    <font>font30_title</font>
                    <label>$INFO[Window.Property(WCS.AIChat.GlitchText)]</label>
                    <textcolor>button_focus</textcolor>
                    <align>center</align>
                    <aligny>center</aligny>
                </control>
                <!-- FUN STATUS (Center) -->
                <control type="label">
                    <left>0</left>
                    <top>210</top>
                    <width>540</width>
                    <height>30</height>
                    <font>font12</font>
                    <label>--- $INFO[Window.Property(WCS.AIChat.FunStatus)] ---</label>
                    <textcolor>grey</textcolor>
                    <align>center</align>
                </control>
                
                <!-- PROVIDER (Left - Cyan) -->
                <control type="label">
                    <left>20</left>
                    <top>15</top>
                    <width>260</width>
                    <height>25</height>
                    <font>font10</font>
                    <label>$INFO[Window.Property(WCS.AIChat.Provider)]</label>
                    <textcolor>0xFF00FFFF</textcolor>
                    <align>left</align>
                </control>
                
                <!-- MODEL (Right - Orange) -->
                <control type="label">
                    <left>280</left>
                    <top>15</top>
                    <width>250</width>
                    <height>25</height>
                    <font>font10</font>
                    <label>$INFO[Window.Property(WCS.AIChat.Model)]</label>
                    <textcolor>0xFFFFA500</textcolor>
                    <align>right</align>
                </control>
                
                <!-- Dummy Hidden Button to Trap Focus -->
                <control type="button" id="5501">
                    <left>-100</left>
                    <top>-100</top>
                    <width>1</width>
                    <height>1</height>
                    <texturefocus></texturefocus>
                    <texturenofocus></texturenofocus>
                    <onup>noop</onup>
                    <ondown>noop</ondown>
                    <onleft>noop</onleft>
                    <onright>noop</onright>
                    <onclick>noop</onclick>
                </control>
            </control>
            
            <!-- Input Field -->
            <control type="edit" id="3000">
                <left>1350</left>
                <top>1000</top>
                <width>430</width>
                <height>50</height>
                <font>font13</font>
                <ondown>noop</ondown>
                <onup>4000</onup>
                <onright>3001</onright>
                <label>Zeptej se AI...</label>
                <texturefocus border="25" colordiffuse="40FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturefocus>
                <texturenofocus border="25" colordiffuse="20FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturenofocus>
            </control>
            
            <!-- Send Button -->
            <control type="button" id="3001">
                <left>1790</left>
                <top>1000</top>
                <width>100</width>
                <height>50</height>
                <label>Send</label>
                <font>font12</font>
                <textcolor>FFFFFFFF</textcolor>
                <focusedcolor>FF00AAFF</focusedcolor>
                <align>center</align>
                <aligny>center</aligny>
                <texturefocus border="25" colordiffuse="60FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturefocus>
                <texturenofocus border="25" colordiffuse="20FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturenofocus>
                <onleft>3000</onleft>
                <ondown>4000</ondown>
            </control>
        </control>
        
        <!-- Subtle Hint to open chat if hidden -->
        <control type="group">
            <visible>![Control.HasFocus(4000) | Control.HasFocus(3000) | Control.HasFocus(3001) | !String.IsEmpty(Window.Property(WCS.AIChat.Visible))]</visible>
            <left>1850</left>
            <top>500</top>
            <control type="image">
                 <width>50</width>
                 <height>100</height>
                 <texture flipx="true">common/arrow_right.png</texture>
                 <colordiffuse>80FFFFFF</colordiffuse>
            </control>
        </control>

        <!-- ==================================================================================== -->
        <!-- ADD SERIES DIALOG (Inline - was DialogAddSeries.xml) -->
        <!-- ==================================================================================== -->
        
        <!-- Dim overlay (separate group for fade animation) -->
        <control type="group">
            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.Active))</visible>
            <animation effect="fade" start="0" end="100" time="3000">Visible</animation>
            <animation effect="fade" start="100" end="0" time="200">Hidden</animation>
            <control type="image">
                <left>0</left>
                <top>0</top>
                <width>1920</width>
                <height>1080</height>
                <texture colordiffuse="70000000">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
            </control>
        </control>
        
        <!-- Floating panel (separate group for slide animation) -->
        <control type="group">
            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.Active))</visible>
            <animation effect="slide" start="0,900" end="0,0" time="400" tween="cubic" easing="out">Visible</animation>
            <animation effect="slide" start="0,0" end="0,900" time="300" tween="cubic" easing="out">Hidden</animation>
            
            <!-- Floating panel container -->
            <control type="group">
                <left>160</left>
                <top>180</top>
                <width>1600</width>
                <height>720</height>

                <!-- Panel background with rounded corners -->
                <control type="image">
                    <left>0</left>
                    <top>0</top>
                    <width>1600</width>
                    <height>720</height>
                    <texture border="30">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texture>
                    <colordiffuse>F01A1A1A</colordiffuse>
                </control>
                
                <!-- Close button (X) -->
                <control type="button" id="9200">
                    <left>1530</left>
                    <top>15</top>
                    <width>50</width>
                    <height>50</height>
                    <font>font30</font>
                    <label>X</label>
                    <align>center</align>
                    <aligny>center</aligny>
                    <ondown>9201</ondown>
                    <onleft>9204</onleft>
                    <texturefocus border="20" colordiffuse="80FF4444">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturefocus>
                    <texturenofocus border="20" colordiffuse="40FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texturenofocus>
                </control>
                
                <!-- ============================================ -->
                <!-- STATE 1: Action Selection -->
                <!-- ============================================ -->
                <control type="group">
                    <visible>String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ListingMode))</visible>
                    
                    <!-- Title (TV Mode) -->
                    <control type="label">
                        <left>50</left>
                        <top>25</top>
                        <width>1400</width>
                        <height>50</height>
                        <font>font45</font>
                        <label>Pridat serial do kanalu</label>
                        <textcolor>white</textcolor>
                        <visible>!String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
                    </control>
                    <!-- Title (Cinema Mode) -->
                    <control type="label">
                        <left>50</left>
                        <top>25</top>
                        <width>1400</width>
                        <height>50</height>
                        <font>font45</font>
                        <label>Pridat film do kina</label>
                        <textcolor>white</textcolor>
                        <visible>String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
                    </control>
                    
                    <!-- 4 Action Cards Container -->
                    <control type="group" id="9205">
                        <left>50</left>
                        <top>100</top>
                        <width>1500</width>
                        <height>280</height>
                        
                        <!-- Card 1: Z mojí knihovny -->
                        <control type="group">
                            <left>0</left>
                            <top>0</top>
                            <width>340</width>
                            <height>280</height>
                            <control type="button" id="9201">
                                <left>0</left>
                                <top>0</top>
                                <width>340</width>
                                <height>200</height>
                                <label></label>
                                <onup>9200</onup>
                                <ondown>noop</ondown>
                                <onright>9202</onright>
                                <texturefocus colordiffuse="FFFFFFFF">special://home/addons/plugin.video.milionar/resources/media/card_my_library.jpg</texturefocus>
                                <texturenofocus colordiffuse="80FFFFFF">special://home/addons/plugin.video.milionar/resources/media/card_my_library.jpg</texturenofocus>
                            </control>
                            <control type="label">
                                <left>0</left>
                                <top>210</top>
                                <width>340</width>
                                <height>40</height>
                                <font>font27</font>
                                <label>Z mojí knihovny</label>
                                <textcolor>FFFFFFFF</textcolor>
                                <align>center</align>
                                <visible>Control.HasFocus(9201)</visible>
                            </control>
                            <control type="label">
                                <left>0</left>
                                <top>210</top>
                                <width>340</width>
                                <height>40</height>
                                <font>font27</font>
                                <label>Z mojí knihovny</label>
                                <textcolor>80FFFFFF</textcolor>
                                <align>center</align>
                                <visible>!Control.HasFocus(9201)</visible>
                            </control>
                        </control>
                        
                        <!-- Card 2: Vyhledat na TMDb -->
                        <control type="group">
                            <left>370</left>
                            <top>0</top>
                            <width>340</width>
                            <height>280</height>
                            <control type="button" id="9202">
                                <left>0</left>
                                <top>0</top>
                                <width>340</width>
                                <height>200</height>
                                <label></label>
                                <onup>9200</onup>
                                <ondown>noop</ondown>
                                <onleft>9201</onleft>
                                <onright>9203</onright>
                                <texturefocus colordiffuse="FFFFFFFF">special://home/addons/plugin.video.milionar/resources/media/card_search_tmdb.jpg</texturefocus>
                                <texturenofocus colordiffuse="80FFFFFF">special://home/addons/plugin.video.milionar/resources/media/card_search_tmdb.jpg</texturenofocus>
                            </control>
                            <control type="label">
                                <left>0</left>
                                <top>210</top>
                                <width>340</width>
                                <height>40</height>
                                <font>font27</font>
                                <label>Vyhledat na TMDb</label>
                                <textcolor>FFFFFFFF</textcolor>
                                <align>center</align>
                                <visible>Control.HasFocus(9202)</visible>
                            </control>
                            <control type="label">
                                <left>0</left>
                                <top>210</top>
                                <width>340</width>
                                <height>40</height>
                                <font>font27</font>
                                <label>Vyhledat na TMDb</label>
                                <textcolor>80FFFFFF</textcolor>
                                <align>center</align>
                                <visible>!Control.HasFocus(9202)</visible>
                            </control>
                        </control>
                        
                        <!-- Card 3: Doporučit z TMDb -->
                        <control type="group">
                            <left>740</left>
                            <top>0</top>
                            <width>340</width>
                            <height>280</height>
                            <control type="button" id="9203">
                                <left>0</left>
                                <top>0</top>
                                <width>340</width>
                                <height>200</height>
                                <label></label>
                                <onup>9200</onup>
                                <ondown>noop</ondown>
                                <onleft>9202</onleft>
                                <onright>9204</onright>
                                <texturefocus colordiffuse="FFFFFFFF">special://home/addons/plugin.video.milionar/resources/media/card_tmdb_recommend.jpg</texturefocus>
                                <texturenofocus colordiffuse="80FFFFFF">special://home/addons/plugin.video.milionar/resources/media/card_tmdb_recommend.jpg</texturenofocus>
                            </control>
                            <control type="label">
                                <left>0</left>
                                <top>210</top>
                                <width>340</width>
                                <height>40</height>
                                <font>font27</font>
                                <label>Doporučit z TMDb</label>
                                <textcolor>FFFFFFFF</textcolor>
                                <align>center</align>
                                <visible>Control.HasFocus(9203)</visible>
                            </control>
                            <control type="label">
                                <left>0</left>
                                <top>210</top>
                                <width>340</width>
                                <height>40</height>
                                <font>font27</font>
                                <label>Doporučit z TMDb</label>
                                <textcolor>80FFFFFF</textcolor>
                                <align>center</align>
                                <visible>!Control.HasFocus(9203)</visible>
                            </control>
                        </control>
                        
                        <!-- Card 4: Doporučit od AI -->
                        <control type="group">
                            <left>1110</left>
                            <top>0</top>
                            <width>340</width>
                            <height>280</height>
                            <control type="button" id="9204">
                                <left>0</left>
                                <top>0</top>
                                <width>340</width>
                                <height>200</height>
                                <label></label>
                                <onup>9200</onup>
                                <ondown>noop</ondown>
                                <onleft>9203</onleft>
                                <texturefocus colordiffuse="FFFFFFFF">special://home/addons/plugin.video.milionar/resources/media/card_ai_recommend.jpg</texturefocus>
                                <texturenofocus colordiffuse="80FFFFFF">special://home/addons/plugin.video.milionar/resources/media/card_ai_recommend.jpg</texturenofocus>
                            </control>
                            <control type="label">
                                <left>0</left>
                                <top>210</top>
                                <width>340</width>
                                <height>40</height>
                                <font>font27</font>
                                <label>Doporučit od AI</label>
                                <textcolor>FFFFFFFF</textcolor>
                                <align>center</align>
                                <visible>Control.HasFocus(9204)</visible>
                            </control>
                            <control type="label">
                                <left>0</left>
                                <top>210</top>
                                <width>340</width>
                                <height>40</height>
                                <font>font27</font>
                                <label>Doporučit od AI</label>
                                <textcolor>80FFFFFF</textcolor>
                                <align>center</align>
                                <visible>!Control.HasFocus(9204)</visible>
                            </control>
                        </control>
                    </control>
                    
                    <!-- Dynamic description based on focus -->
                    <control type="label">
                        <left>50</left>
                        <top>530</top>
                        <width>1500</width>
                        <height>80</height>
                        <font>font24</font>
                        <label>$INFO[Window.Property(WCS.MyTV.AddDialog.Description)]</label>
                        <textcolor>AAFFFFFF</textcolor>
                        <align>center</align>
                        <wrapmultiline>true</wrapmultiline>
                    </control>
                </control>
                
                <!-- ============================================ -->
                <!-- STATE 2: Series Listing -->
                <!-- ============================================ -->
                <control type="group">
                    <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ListingMode)) + String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.AILoading))</visible>
                    
                    <!-- Title (dynamic based on mode) -->
                    <control type="label">
                        <left>50</left>
                        <top>25</top>
                        <width>1400</width>
                        <height>50</height>
                        <font>font45</font>
                        <label>$INFO[Window.Property(WCS.MyTV.AddDialog.ListingTitle)]</label>
                        <textcolor>white</textcolor>
                    </control>
                    
                    <!-- Series horizontal list -->
                    <control type="wraplist" id="9211">
                        <left>50</left>
                        <top>100</top>
                        <width>900</width>
                        <height>580</height>
                        <orientation>horizontal</orientation>
                        <scrolltime tween="cubic" easing="out">300</scrolltime>
                        <preloaditems>3</preloaditems>
                        <onup>9200</onup>
                        <ondown>noop</ondown>
                        <onright>noop</onright>
                        
                        <itemlayout height="520" width="200">
                            <control type="image">
                                <left>10</left>
                                <top>20</top>
                                <width>180</width>
                                <height>270</height>
                                <texture fallback="special://home/addons/plugin.video.milionar/resources/media/placeholder_tv_card.jpg" diffuse="special://home/addons/plugin.video.milionar/resources/media/card_mask.png">$INFO[ListItem.Art(poster)]</texture>
                                <aspectratio>stretch</aspectratio>
                            </control>
                            <!-- Checkmark for added series -->
                            <control type="image">
                                <right>15</right>
                                <top>25</top>
                                <width>40</width>
                                <height>40</height>
                                <texture colordiffuse="FF00CC66">special://home/addons/plugin.video.milionar/resources/media/checkmark.png</texture>
                                <visible>String.IsEqual(ListItem.Property(is_added),true)</visible>
                            </control>
                            <!-- Series name -->
                            <control type="label">
                                <left>10</left>
                                <top>300</top>
                                <width>180</width>
                                <height>60</height>
                                <font>font10</font>
                                <label>$INFO[ListItem.Label]</label>
                                <textcolor>AAFFFFFF</textcolor>
                                <align>center</align>
                                <wrapmultiline>true</wrapmultiline>
                            </control>
                        </itemlayout>
                        
                        <focusedlayout height="520" width="200">
                            <control type="image">
                                <left>5</left>
                                <top>15</top>
                                <width>190</width>
                                <height>285</height>
                                <texture fallback="special://home/addons/plugin.video.milionar/resources/media/placeholder_tv_card.jpg" diffuse="special://home/addons/plugin.video.milionar/resources/media/card_mask.png">$INFO[ListItem.Art(poster)]</texture>
                                <aspectratio>stretch</aspectratio>
                                <animation effect="zoom" start="100" end="108" center="auto" time="150">Focus</animation>
                            </control>
                            <!-- Focus border -->
                            <control type="image">
                                <left>0</left>
                                <top>10</top>
                                <width>200</width>
                                <height>295</height>
                                <texture colordiffuse="CCFFFFFF">special://home/addons/plugin.video.milionar/resources/media/card_border_focus.png</texture>
                                <aspectratio>stretch</aspectratio>
                                <animation effect="zoom" start="100" end="108" center="auto" time="150">Focus</animation>
                            </control>
                            <!-- Checkmark for added series -->
                            <control type="image">
                                <right>10</right>
                                <top>20</top>
                                <width>45</width>
                                <height>45</height>
                                <texture colordiffuse="FF00CC66">special://home/addons/plugin.video.milionar/resources/media/checkmark.png</texture>
                                <visible>String.IsEqual(ListItem.Property(is_added),true)</visible>
                                <animation effect="zoom" start="100" end="108" center="auto" time="150">Focus</animation>
                            </control>
                            <!-- Series name -->
                            <control type="label">
                                <left>10</left>
                                <top>310</top>
                                <width>180</width>
                                <height>60</height>
                                <font>font10</font>
                                <label>$INFO[ListItem.Label]</label>
                                <textcolor>white</textcolor>
                                <align>center</align>
                                <wrapmultiline>true</wrapmultiline>
                                <scroll>true</scroll>
                            </control>
                        </focusedlayout>
                    </control>
                    
                    <!-- Metadata Panel (right side) -->
                    <control type="group">
                        <left>980</left>
                        <top>100</top>
                        <width>580</width>
                        <height>580</height>
                        
                        <!-- Metadata background -->
                        <control type="image">
                            <left>0</left>
                            <top>0</top>
                            <width>580</width>
                            <height>580</height>
                            <texture border="20" colordiffuse="40000000">special://home/addons/plugin.video.milionar/resources/media/panel_bg_rounded.png</texture>
                        </control>
                        
                        <!-- Fanart/backdrop -->
                        <control type="image">
                            <left>20</left>
                            <top>20</top>
                            <width>540</width>
                            <height>200</height>
                            <texture fallback="special://home/addons/plugin.video.milionar/resources/media/fanart_fallback.jpg" diffuse="special://home/addons/plugin.video.milionar/resources/media/still_mask_rounded.png">$INFO[Container(9211).ListItem.Art(fanart)]</texture>
                            <aspectratio>scale</aspectratio>
                        </control>
                        
                        <!-- Series title -->
                        <control type="label">
                            <left>20</left>
                            <top>235</top>
                            <width>540</width>
                            <height>45</height>
                            <font>font37</font>
                            <label>$INFO[Container(9211).ListItem.Label]</label>
                            <textcolor>white</textcolor>
                        </control>
                        
                        <!-- Year and genre -->
                        <control type="label">
                            <left>20</left>
                            <top>285</top>
                            <width>540</width>
                            <height>30</height>
                            <font>font13</font>
                            <label>$INFO[Container(9211).ListItem.Property(year)] | $INFO[Container(9211).ListItem.Property(genre)]</label>
                            <textcolor>80FFFFFF</textcolor>
                        </control>
                        
                        <!-- Rating -->
                        <control type="label">
                            <left>20</left>
                            <top>320</top>
                            <width>540</width>
                            <height>30</height>
                            <font>font12</font>
                            <label>Hodnocení: $INFO[Container(9211).ListItem.Property(rating)]</label>
                            <textcolor>FFCCAA00</textcolor>
                            <visible>!String.IsEmpty(Container(9211).ListItem.Property(rating))</visible>
                        </control>
                        
                        <!-- Plot -->
                        <control type="textbox">
                            <left>20</left>
                            <top>360</top>
                            <width>540</width>
                            <height>200</height>
                            <font>font12</font>
                            <label>$INFO[Container(9211).ListItem.Property(plot)]</label>
                            <textcolor>AAFFFFFF</textcolor>
                            <autoscroll delay="4000" time="2000" repeat="4000">true</autoscroll>
                        </control>
                    </control>
                    
                    <!-- Hint text area -->
                    <control type="group">
                        <left>50</left>
                        <top>580</top>
                        <width>900</width>
                        <height>30</height>
                        
                        <!-- Default hint when no actions visible -->
                        <control type="label">
                            <left>0</left>
                            <top>0</top>
                            <width>900</width>
                            <height>30</height>
                            <font>font24</font>
                            <label>Stiskni ENTER pro zobrazení možností</label>
                            <textcolor>60FFFFFF</textcolor>
                            <align>center</align>
                            <visible>String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ActionsVisible))</visible>
                        </control>
                        
                        <!-- Action button descriptions when actions visible -->
                        <!-- Button 1: Pridat do kanalu (TV) -->
                        <control type="label">
                            <left>0</left>
                            <top>0</top>
                            <width>900</width>
                            <height>30</height>
                            <font>font24</font>
                            <label>Pridat serial do tohoto kanalu</label>
                            <textcolor>80FFFFFF</textcolor>
                            <align>center</align>
                            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ActionsVisible)) + String.IsEqual(Container(9220).ListItem.Property(action_id),add_to_channel) + !String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
                        </control>
                        <!-- Button 1: Pridat do kina (Cinema) -->
                        <control type="label">
                            <left>0</left>
                            <top>0</top>
                            <width>900</width>
                            <height>30</height>
                            <font>font24</font>
                            <label>Pridat film do tohoto kina</label>
                            <textcolor>80FFFFFF</textcolor>
                            <align>center</align>
                            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ActionsVisible)) + String.IsEqual(Container(9220).ListItem.Property(action_id),add_to_channel) + String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
                        </control>
                        
                        <!-- Button 2: Moje serialy (TV) - matches both old and new action_id -->
                        <control type="label">
                            <left>0</left>
                            <top>0</top>
                            <width>900</width>
                            <height>30</height>
                            <font>font24</font>
                            <label>Pridat do knihovny Moje serialy</label>
                            <textcolor>80FFFFFF</textcolor>
                            <align>center</align>
                            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ActionsVisible)) + [String.IsEqual(Container(9220).ListItem.Property(action_id),add_to_my_series) | String.IsEqual(Container(9220).ListItem.Property(action_id),add_to_my_library)] + !String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
                        </control>
                        <!-- Button 2: Moje filmy (Cinema) - matches both old and new action_id -->
                        <control type="label">
                            <left>0</left>
                            <top>0</top>
                            <width>900</width>
                            <height>30</height>
                            <font>font24</font>
                            <label>Pridat do knihovny Moje filmy</label>
                            <textcolor>80FFFFFF</textcolor>
                            <align>center</align>
                            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ActionsVisible)) + [String.IsEqual(Container(9220).ListItem.Property(action_id),add_to_my_series) | String.IsEqual(Container(9220).ListItem.Property(action_id),add_to_my_library)] + String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
                        </control>
                        
                        <!-- Button 3: Podobne (TV) -->
                        <control type="label">
                            <left>0</left>
                            <top>0</top>
                            <width>900</width>
                            <height>30</height>
                            <font>font24</font>
                            <label>Zobrazit podobne serialy z TMDb</label>
                            <textcolor>80FFFFFF</textcolor>
                            <align>center</align>
                            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ActionsVisible)) + String.IsEqual(Container(9220).ListItem.Property(action_id),find_similar) + !String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
                        </control>
                        <!-- Button 3: Podobne (Cinema) -->
                        <control type="label">
                            <left>0</left>
                            <top>0</top>
                            <width>900</width>
                            <height>30</height>
                            <font>font24</font>
                            <label>Zobrazit podobne filmy z TMDb</label>
                            <textcolor>80FFFFFF</textcolor>
                            <align>center</align>
                            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ActionsVisible)) + String.IsEqual(Container(9220).ListItem.Property(action_id),find_similar) + String.IsEqual(Window.Property(WCS.MediaType),cinema)</visible>
                        </control>
                        
                        <!-- Button 4: Hrát hru -->
                        <control type="label">
                            <left>0</left>
                            <top>0</top>
                            <width>900</width>
                            <height>30</height>
                            <font>font24</font>
                            <label>Spustit kvíz Milionář o tomto seriálu</label>
                            <textcolor>80FFFFFF</textcolor>
                            <align>center</align>
                            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ActionsVisible)) + String.IsEqual(Container(9220).ListItem.Property(action_id),play_game)</visible>
                        </control>
                    </control>
                    
                    <!-- ACTION BUTTONS OVERLAY (Slide down from poster area) -->
                    <control type="group">
                        <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.ActionsVisible))</visible>
                        <animation effect="slide" start="0,-50" end="0,0" time="250" tween="cubic" easing="out">Visible</animation>
                        <animation effect="slide" start="0,0" end="0,-50" time="150" tween="cubic" easing="in">Hidden</animation>
                        <animation effect="fade" start="0" end="100" time="250">Visible</animation>
                        <animation effect="fade" start="100" end="0" time="150">Hidden</animation>
                        
                        <!-- Action buttons list - directly under posters -->
                        <control type="list" id="9220">
                            <left>50</left>
                            <top>450</top>
                            <width>900</width>
                            <height>55</height>
                            <orientation>horizontal</orientation>
                            <onup>9211</onup>
                            <ondown>noop</ondown>
                            <onleft>noop</onleft>
                            <onright>noop</onright>
                            
                            <itemlayout height="50" width="225">
                                <!-- Default: Subtle transparent pill background -->
                                <control type="image">
                                    <left>5</left>
                                    <top>0</top>
                                    <width>215</width>
                                    <height>50</height>
                                    <texture border="25" colordiffuse="25808080">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texture>
                                </control>
                                <control type="label">
                                    <left>5</left>
                                    <top>0</top>
                                    <width>215</width>
                                    <height>50</height>
                                    <align>center</align>
                                    <aligny>center</aligny>
                                    <label>$INFO[ListItem.Label]</label>
                                    <textcolor>AAFFFFFF</textcolor>
                                    <font>font24</font>
                                </control>
                            </itemlayout>
                            
                            <focusedlayout height="50" width="225">
                                <!-- Unfocused state (list has focus but item not selected) -->
                                <control type="group">
                                    <visible>!Control.HasFocus(9220)</visible>
                                    <control type="image">
                                        <left>5</left>
                                        <top>0</top>
                                        <width>215</width>
                                        <height>50</height>
                                        <texture border="25" colordiffuse="25808080">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texture>
                                    </control>
                                    <control type="label">
                                        <left>5</left>
                                        <top>0</top>
                                        <width>215</width>
                                        <height>50</height>
                                        <align>center</align>
                                        <aligny>center</aligny>
                                        <label>$INFO[ListItem.Label]</label>
                                        <textcolor>AAFFFFFF</textcolor>
                                        <font>font24</font>
                                    </control>
                                </control>

                                <!-- Focused state: Brighter -->
                                <control type="group">
                                    <visible>Control.HasFocus(9220)</visible>
                                    <!-- Brighter pill background -->
                                    <control type="image">
                                        <left>5</left>
                                        <top>0</top>
                                        <width>215</width>
                                        <height>50</height>
                                        <texture border="25" colordiffuse="60FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texture>
                                    </control>
                                    <!-- White text -->
                                    <control type="label">
                                        <left>5</left>
                                        <top>0</top>
                                        <width>215</width>
                                        <height>50</height>
                                        <align>center</align>
                                        <aligny>center</aligny>
                                        <label>$INFO[ListItem.Label]</label>
                                        <textcolor>FFFFFFFF</textcolor>
                                        <font>font24</font>
                                    </control>
                                </control>
                            </focusedlayout>
                        </control>
                    </control>
                </control>
                
                <!-- ============================================ -->
                <!-- STATE 3: AI Loading Matrix Overlay -->
                <!-- ============================================ -->
                <control type="group">
                    <visible>!String.IsEmpty(Window.Property(WCS.MyTV.AddDialog.AILoading))</visible>
                    <animation effect="fade" start="0" end="100" time="400">Visible</animation>
                    <animation effect="fade" start="100" end="0" time="200">Hidden</animation>
                    
                    <!-- Full panel background with subtle gradient -->
                    <control type="image">
                        <left>0</left>
                        <top>0</top>
                        <width>1600</width>
                        <height>720</height>
                        <texture border="30">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texture>
                        <colordiffuse>F0121218</colordiffuse>
                    </control>
                    
                    <!-- Subtle scan line overlay for Matrix effect -->
                    <control type="image">
                        <left>0</left>
                        <top>0</top>
                        <width>1600</width>
                        <height>720</height>
                        <texture border="30" colordiffuse="08FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texture>
                        <animation effect="fade" start="30" end="80" time="1500" loop="true" reversible="true" pulse="true">Visible</animation>
                    </control>
                    
                    <!-- ======= HEADER SECTION ======= -->
                    <control type="group">
                        <left>50</left>
                        <top>40</top>
                        <width>1500</width>
                        <height>80</height>
                        
                        <!-- Main Title - "AI přemýšlí" with glow -->
                        <control type="label">
                            <left>0</left>
                            <top>0</top>
                            <width>1500</width>
                            <height>55</height>
                            <font>font45</font>
                            <label>AI přemýšlí</label>
                            <textcolor>FF00AAFF</textcolor>
                            <align>center</align>
                            <animation effect="fade" start="70" end="100" time="800" loop="true" reversible="true" pulse="true">Visible</animation>
                        </control>
                        
                        <!-- Subtitle with status -->
                        <control type="label">
                            <left>0</left>
                            <top>55</top>
                            <width>1500</width>
                            <height>25</height>
                            <font>font13</font>
                            <label>$INFO[Window.Property(WCS.MyTV.AddDialog.AIStatus)]</label>
                            <textcolor>80FFFFFF</textcolor>
                            <align>center</align>
                        </control>
                    </control>
                    
                    <!-- ======= CENTER MATRIX ANIMATION AREA ======= -->
                    <control type="group">
                        <left>0</left>
                        <top>150</top>
                        <width>1600</width>
                        <height>380</height>
                        
                        <!-- Animated glitch text - Large centered -->
                        <control type="label">
                            <left>0</left>
                            <top>100</top>
                            <width>1600</width>
                            <height>80</height>
                            <font>font_fallback</font>
                            <label>$INFO[Window.Property(WCS.MyTV.AddDialog.GlitchText)]</label>
                            <textcolor>FF00FF88</textcolor>
                            <align>center</align>
                            <aligny>center</aligny>
                            <animation effect="zoom" start="98" end="102" center="auto" time="600" loop="true" reversible="true" pulse="true">Visible</animation>
                            <animation effect="fade" start="60" end="100" time="400" loop="true" reversible="true" pulse="true">Visible</animation>
                        </control>
                        
                        <!-- Decorative animated dots (loading indicator) -->
                        <control type="group">
                            <left>700</left>
                            <top>200</top>
                            <width>200</width>
                            <height>30</height>
                            
                            <!-- Dot 1 -->
                            <control type="image">
                                <left>30</left>
                                <top>5</top>
                                <width>20</width>
                                <height>20</height>
                                <texture colordiffuse="FF00AAFF">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                                <animation effect="fade" start="30" end="100" time="500" delay="0" loop="true" reversible="true" pulse="true">Visible</animation>
                                <animation effect="zoom" start="80" end="100" center="auto" time="500" delay="0" loop="true" reversible="true" pulse="true">Visible</animation>
                            </control>
                            
                            <!-- Dot 2 -->
                            <control type="image">
                                <left>70</left>
                                <top>5</top>
                                <width>20</width>
                                <height>20</height>
                                <texture colordiffuse="FF00FF88">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                                <animation effect="fade" start="30" end="100" time="500" delay="200" loop="true" reversible="true" pulse="true">Visible</animation>
                                <animation effect="zoom" start="80" end="100" center="auto" time="500" delay="200" loop="true" reversible="true" pulse="true">Visible</animation>
                            </control>
                            
                            <!-- Dot 3 -->
                            <control type="image">
                                <left>110</left>
                                <top>5</top>
                                <width>20</width>
                                <height>20</height>
                                <texture colordiffuse="FF00AAFF">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                                <animation effect="fade" start="30" end="100" time="500" delay="400" loop="true" reversible="true" pulse="true">Visible</animation>
                                <animation effect="zoom" start="80" end="100" center="auto" time="500" delay="400" loop="true" reversible="true" pulse="true">Visible</animation>
                            </control>
                            
                            <!-- Dot 4 -->
                            <control type="image">
                                <left>150</left>
                                <top>5</top>
                                <width>20</width>
                                <height>20</height>
                                <texture colordiffuse="FF00FF88">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                                <animation effect="fade" start="30" end="100" time="500" delay="600" loop="true" reversible="true" pulse="true">Visible</animation>
                                <animation effect="zoom" start="80" end="100" center="auto" time="500" delay="600" loop="true" reversible="true" pulse="true">Visible</animation>
                            </control>
                        </control>
                        
                        <!-- Fun status message -->
                        <control type="label">
                            <left>0</left>
                            <top>260</top>
                            <width>1600</width>
                            <height>30</height>
                            <font>font12</font>
                            <label>--- $INFO[Window.Property(WCS.MyTV.AddDialog.FunStatus)] ---</label>
                            <textcolor>60FFFFFF</textcolor>
                            <align>center</align>
                            <animation effect="fade" start="50" end="100" time="1200" loop="true" reversible="true" pulse="true">Visible</animation>
                        </control>
                    </control>
                    
                    <!-- ======= BOTTOM INFO BAR ======= -->
                    <control type="group">
                        <left>50</left>
                        <top>560</top>
                        <width>1500</width>
                        <height>120</height>
                        
                        <!-- Separator line -->
                        <control type="image">
                            <left>400</left>
                            <top>0</top>
                            <width>700</width>
                            <height>2</height>
                            <texture colordiffuse="30FFFFFF">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                        </control>
                        
                        <!-- Provider info (Left - Cyan) -->
                        <control type="label">
                            <left>0</left>
                            <top>20</top>
                            <width>600</width>
                            <height>30</height>
                            <font>font13</font>
                            <label>Provider: $INFO[Window.Property(WCS.MyTV.AddDialog.Provider)]</label>
                            <textcolor>FF00FFFF</textcolor>
                            <align>left</align>
                        </control>
                        
                        <!-- Model info (Left below provider) -->
                        <control type="label">
                            <left>0</left>
                            <top>55</top>
                            <width>1000</width>
                            <height>30</height>
                            <font>font13</font>
                            <label>Model: $INFO[Window.Property(WCS.MyTV.AddDialog.Model)]</label>
                            <textcolor>FFFFA500</textcolor>
                            <align>left</align>
                        </control>
                        
                        <!-- Timer (Right side - prominent) -->
                        <control type="label">
                            <left>900</left>
                            <top>30</top>
                            <width>600</width>
                            <height>50</height>
                            <font>font45</font>
                            <label>$INFO[Window.Property(WCS.MyTV.AddDialog.Timer)]</label>
                            <textcolor>FF00AAFF</textcolor>
                            <align>right</align>
                            <animation effect="fade" start="80" end="100" time="500" loop="true" reversible="true" pulse="true">Visible</animation>
                        </control>
                    </control>
                    
                    <!-- Hidden button to trap focus during loading -->
                    <control type="button" id="9250">
                        <left>-100</left>
                        <top>-100</top>
                        <width>1</width>
                        <height>1</height>
                        <texturefocus></texturefocus>
                        <texturenofocus></texturenofocus>
                        <onup>noop</onup>
                        <ondown>noop</ondown>
                        <onleft>noop</onleft>
                        <onright>noop</onright>
                        <onclick>noop</onclick>
                    </control>
                </control>
                
            </control>
        </control>

        <!-- ==================================================================================== -->
        <!-- SERIES DETAIL DIALOG (Inline - shows when clicking on series in grid) -->
        <!-- ==================================================================================== -->
        
        <!-- Dim overlay -->
        <control type="group">
            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.SeriesDetail.Active))</visible>
            <animation effect="fade" start="0" end="100" time="200">Visible</animation>
            <animation effect="fade" start="100" end="0" time="150">Hidden</animation>
            <control type="image">
                <left>0</left>
                <top>0</top>
                <width>1920</width>
                <height>1080</height>
                <texture colordiffuse="60000000">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
            </control>
        </control>
        
        <!-- Series Detail Panel - positioned exactly over the grid area -->
        <control type="group">
            <visible>!String.IsEmpty(Window.Property(WCS.MyTV.SeriesDetail.Active))</visible>
            <animation effect="slide" start="-900,0" end="0,0" time="350" tween="cubic" easing="out">Visible</animation>
            <animation effect="slide" start="0,0" end="-900,0" time="250" tween="cubic" easing="in">Hidden</animation>
            
            <!-- Main panel container - same position as grid -->
            <control type="group">
                <left>60</left>
                <top>200</top>
                <width>960</width>
                <height>430</height>
                
                <!-- Panel background with rounded corners -->
                <control type="image">
                    <left>0</left>
                    <top>0</top>
                    <width>960</width>
                    <height>430</height>
                    <texture border="30">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texture>
                    <colordiffuse>F0151520</colordiffuse>
                </control>
                
                <!-- Fanart backdrop (left side, cropped) -->
                <control type="image">
                    <left>15</left>
                    <top>15</top>
                    <width>400</width>
                    <height>400</height>
                    <texture fallback="special://home/addons/plugin.video.milionar/resources/media/fanart_fallback.jpg" diffuse="special://home/addons/plugin.video.milionar/resources/media/card_mask_large.png">$INFO[Window.Property(WCS.MyTV.SeriesDetail.Fanart)]</texture>
                    <aspectratio>scale</aspectratio>
                </control>
                
                <!-- Gradient overlay on fanart for better text readability -->
                <control type="image">
                    <left>15</left>
                    <top>15</top>
                    <width>400</width>
                    <height>400</height>
                    <texture colordiffuse="90000000">special://home/addons/plugin.video.milionar/resources/media/gradient_right.png</texture>
                </control>
                
                <!-- Series Logo (over fanart, bottom) -->
                <control type="image">
                    <left>30</left>
                    <top>300</top>
                    <width>370</width>
                    <height>100</height>
                    <texture>$INFO[Window.Property(WCS.MyTV.SeriesDetail.Logo)]</texture>
                    <aspectratio aligny="bottom">keep</aspectratio>
                    <visible>!String.IsEmpty(Window.Property(WCS.MyTV.SeriesDetail.Logo))</visible>
                </control>
                
                <!-- Series name (fallback when no logo) -->
                <control type="label">
                    <left>30</left>
                    <top>330</top>
                    <width>370</width>
                    <height>60</height>
                    <font>font45</font>
                    <label>$INFO[Window.Property(WCS.MyTV.SeriesDetail.Name)]</label>
                    <textcolor>white</textcolor>
                    <shadowcolor>black</shadowcolor>
                    <visible>String.IsEmpty(Window.Property(WCS.MyTV.SeriesDetail.Logo))</visible>
                </control>

                
                <!-- Metadata section (right side - full width without X button) -->
                <control type="group">
                    <left>430</left>
                    <top>10</top>
                    <width>520</width>
                    <height>400</height>
                    
                    <!-- Series title (always shown on right) -->
                    <control type="label">
                        <left>0</left>
                        <top>10</top>
                        <width>520</width>
                        <height>45</height>
                        <font>font37</font>
                        <label>$INFO[Window.Property(WCS.MyTV.SeriesDetail.Name)]</label>
                        <textcolor>white</textcolor>
                    </control>
                    
                    <!-- Year | Genre -->
                    <control type="label">
                        <left>0</left>
                        <top>60</top>
                        <width>520</width>
                        <height>25</height>
                        <font>font13</font>
                        <label>$INFO[Window.Property(WCS.MyTV.SeriesDetail.Year)] | $INFO[Window.Property(WCS.MyTV.SeriesDetail.Genre)]</label>
                        <textcolor>80FFFFFF</textcolor>
                    </control>
                    
                    <!-- Rating -->
                    <control type="label">
                        <left>0</left>
                        <top>95</top>
                        <width>520</width>
                        <height>25</height>
                        <font>font12</font>
                        <label>Hodnocení: $INFO[Window.Property(WCS.MyTV.SeriesDetail.Rating)]</label>
                        <textcolor>FFCCAA00</textcolor>
                        <visible>!String.IsEmpty(Window.Property(WCS.MyTV.SeriesDetail.Rating))</visible>
                    </control>
                    
                    <!-- Plot -->
                    <control type="textbox">
                        <left>0</left>
                        <top>134</top>
                        <width>510</width>
                        <height>202</height>
                        <font>font12</font>
                        <label>$INFO[Window.Property(WCS.MyTV.SeriesDetail.Plot)]</label>
                        <textcolor>AAFFFFFF</textcolor>
                        <autoscroll delay="5000" time="2000" repeat="5000">true</autoscroll>
                    </control>
                    
                    <!-- Buttons row - 4 buttons evenly distributed -->
                    <control type="group">
                        <left>0</left>
                        <top>355</top>
                        <width>520</width>
                        <height>50</height>
                        
                        <!-- Play series button (NEW) -->
                        <control type="button" id="9304">
                            <left>0</left>
                            <top>0</top>
                            <width>150</width>
                            <height>50</height>
                            <font>font12</font>
                            <label>Přehrát</label>
                            <align>center</align>
                            <aligny>center</aligny>
                            <onup>noop</onup>
                            <ondown>noop</ondown>
                            <onleft>noop</onleft>
                            <onright>9302</onright>
                            <texturefocus border="25" colordiffuse="CC44AA44">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturefocus>
                            <texturenofocus border="25" colordiffuse="40808080">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturenofocus>
                        </control>
                        
                        <!-- Play game button -->
                        <control type="button" id="9302">
                            <left>155</left>
                            <top>0</top>
                            <width>150</width>
                            <height>50</height>
                            <font>font12</font>
                            <label>Hrát hru</label>
                            <align>center</align>
                            <aligny>center</aligny>
                            <onup>noop</onup>
                            <ondown>noop</ondown>
                            <onleft>9304</onleft>
                            <onright>9303</onright>
                            <texturefocus border="25" colordiffuse="CCDDAA00">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturefocus>
                            <texturenofocus border="25" colordiffuse="40808080">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturenofocus>
                        </control>
                        
                        <!-- Similar button -->
                        <control type="button" id="9303">
                            <left>310</left>
                            <top>0</top>
                            <width>150</width>
                            <height>50</height>
                            <font>font12</font>
                            <label>Podobné</label>
                            <align>center</align>
                            <aligny>center</aligny>
                            <onup>noop</onup>
                            <ondown>noop</ondown>
                            <onleft>9302</onleft>
                            <onright>9300</onright>
                            <texturefocus border="25" colordiffuse="CC8844FF">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturefocus>
                            <texturenofocus border="25" colordiffuse="40808080">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturenofocus>
                        </control>
                        
                        <!-- Remove from channel button (icon only) -->
                        <control type="button" id="9300">
                            <left>465</left>
                            <top>0</top>
                            <width>50</width>
                            <height>50</height>
                            <label></label>
                            <onup>noop</onup>
                            <ondown>noop</ondown>
                            <onleft>9303</onleft>
                            <onright>noop</onright>
                            <texturefocus border="20" colordiffuse="CCFF4444">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturefocus>
                            <texturenofocus border="20" colordiffuse="40808080">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturenofocus>
                        </control>
                        <!-- Trash icon overlay -->
                        <control type="image">
                            <left>477</left>
                            <top>12</top>
                            <width>26</width>
                            <height>26</height>
                            <texture colordiffuse="FFFFFFFF">special://home/addons/plugin.video.milionar/resources/media/icon_trash.png</texture>
                            <aspectratio>keep</aspectratio>
                        </control>
                    </control>
                    
                    <!-- DELETE SERIES CONFIRMATION INLINE DIALOG -->
                    <control type="group">
                        <left>0</left>
                        <top>350</top>
                        <visible>String.IsEqual(Window.Property(WCS.MyTV.DeleteSeriesConfirm),true)</visible>
                        <animation effect="fade" start="0" end="100" time="200">Visible</animation>
                        <animation effect="fade" start="100" end="0" time="150">Hidden</animation>
                        
                        <!-- Background panel -->
                        <control type="image">
                            <left>0</left>
                            <top>0</top>
                            <width>520</width>
                            <height>57</height>
                            <texture border="25" colordiffuse="FF1a2535">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texture>
                        </control>
                        
                        <!-- Warning text -->
                        <control type="label">
                            <left>20</left>
                            <top>0</top>
                            <width>350</width>
                            <height>57</height>
                            <font>font24</font>
                            <label>Opravdu odebrat seriál?</label>
                            <textcolor>white</textcolor>
                            <align>left</align>
                            <aligny>center</aligny>
                        </control>
                        
                        <!-- Confirm button -->
                        <control type="button" id="9305">
                            <left>342</left>
                            <top>4</top>
                            <width>160</width>
                            <height>50</height>
                            <font>font24</font>
                            <label>Potvrdit</label>
                            <align>center</align>
                            <aligny>center</aligny>
                            <onleft>9305</onleft>
                            <onright>9305</onright>
                            <onup>9305</onup>
                            <ondown>9305</ondown>
                            <texturefocus border="20" colordiffuse="CC44AA44">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturefocus>
                            <texturenofocus border="20" colordiffuse="40FFFFFF">special://home/addons/plugin.video.milionar/resources/media/btn_action_pill.png</texturenofocus>
                        </control>
                    </control>
                </control>
            </control>
        </control>

        <!-- ==================================================================================== -->
        <!-- CUSTOM TOAST NOTIFICATION - Moderní notifikace v pravém horním rohu -->
        <!-- ==================================================================================== -->
        <control type="group">
            <left>1920</left>
            <top>50</top>
            <visible>!String.IsEmpty(Window.Property(WCS.Toast.Visible))</visible>
            
            <!-- Slide-in animace zprava -->
            <animation effect="slide" start="0,0" end="-560,0" time="350" tween="cubic" easing="out">Visible</animation>
            <animation effect="fade" start="0" end="100" time="300" delay="50">Visible</animation>
            
            <!-- Slide-out a fade-out animace -->
            <animation effect="slide" start="-560,0" end="0,0" time="280" tween="cubic" easing="in">Hidden</animation>
            <animation effect="fade" start="100" end="0" time="250">Hidden</animation>
            
            <!-- Vnější glow/shadow efekt pro hloubku -->
            <control type="image">
                <left>-15</left>
                <top>-10</top>
                <width>550</width>
                <height>95</height>
                <texture border="30" colordiffuse="40000000">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texture>
            </control>
            
            <!-- Hlavní pozadí s glassmorphism efektem -->
            <control type="image">
                <left>0</left>
                <top>0</top>
                <width>520</width>
                <height>75</height>
                <texture border="20" colordiffuse="DD0A0A18">special://home/addons/plugin.video.milionar/resources/media/btn_rounded.png</texture>
            </control>
            
            <!-- Subtle gradient overlay pro premium look -->
            <control type="image">
                <left>0</left>
                <top>0</top>
                <width>520</width>
                <height>38</height>
                <texture colordiffuse="15FFFFFF">special://home/addons/plugin.video.milionar/resources/media/gradient_bottom.png</texture>
                <aspectratio>stretch</aspectratio>
                <flipy>true</flipy>
            </control>
            
            <!-- Accent bar vlevo - dynamická barva podle typu -->
            <!-- Info (modrá) -->
            <control type="image">
                <left>12</left>
                <top>15</top>
                <width>4</width>
                <height>45</height>
                <texture colordiffuse="FF4488FF">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                <visible>String.IsEqual(Window.Property(WCS.Toast.Type),info) | String.IsEmpty(Window.Property(WCS.Toast.Type))</visible>
            </control>
            <!-- Success (zelená) -->
            <control type="image">
                <left>12</left>
                <top>15</top>
                <width>4</width>
                <height>45</height>
                <texture colordiffuse="FF44DD66">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                <visible>String.IsEqual(Window.Property(WCS.Toast.Type),success)</visible>
            </control>
            <!-- Warning (oranžová) -->
            <control type="image">
                <left>12</left>
                <top>15</top>
                <width>4</width>
                <height>45</height>
                <texture colordiffuse="FFFFAA44">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                <visible>String.IsEqual(Window.Property(WCS.Toast.Type),warning)</visible>
            </control>
            <!-- Error (červená) -->
            <control type="image">
                <left>12</left>
                <top>15</top>
                <width>4</width>
                <height>45</height>
                <texture colordiffuse="FFFF4455">special://home/addons/plugin.video.milionar/resources/media/white.png</texture>
                <visible>String.IsEqual(Window.Property(WCS.Toast.Type),error)</visible>
            </control>
            
            <!-- Text zprávy -->
            <control type="label">
                <left>30</left>
                <top>0</top>
                <width>475</width>
                <height>75</height>
                <font>font27</font>
                <label>$INFO[Window.Property(WCS.Toast.Message)]</label>
                <textcolor>FFFFFFFF</textcolor>
                <align>left</align>
                <aligny>center</aligny>
            </control>
        </control>

    </controls>
</window>
