/* =========================================================
   HEADER — PICKBOX TV (FINAL VERSION)
========================================================= */

/* Desktop header language switcher navigation */
#dropdownContent div{
    width: 100%;
}

#dropdownContent ul{
    list-style: none;
    margin: 0;
    padding: 0;
    width: 100%;
}

#dropdownContent ul li{
    margin: 0;
    padding: 0;
    width: 100%;
}

#dropdownContent ul li a{
    margin: 0;
    padding: 0;
    font-size: 1.2rem;
    line-height: 1.7rem;
    font-weight: 400;
    font-style: normal;
    font-variant: normal;
    font-family: 'Open Sans', sans-serif;
    color:white;
    display: block;
    width: 100%;
    background: linear-gradient(90deg, rgba(38,53,61,1) 99%, rgba(16,21,25,1) 100%);
    border-left: 3px solid #26353D;
    padding: .7rem 1.7rem;
    transition: background 0.2s, border-left 0.2s ease;
}

#dropdownContent ul li a:hover,
#dropdownContent ul li.wpml-ls-current-language a {
    border-left: .3rem solid #C00038;
    background: linear-gradient(90deg, rgba(38,53,61,1) 43%, rgba(16,21,25,1) 100%);
}

/* Dropdown Content (Hidden by Default) */
.dropdown-content {
    display: none;
    position: absolute;
    background-color: #26353D;
    min-width: 16rem;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.3);
    z-index: 9999;
    right: 0;
    overflow: hidden;
}


/* ----- Global Header ----- */
.main-page-header {
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #101519;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    z-index: 999;
    margin-bottom: 1.7rem;
}

.main-page-header-wrapper {
    width: 95%;
    max-width: 1024px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* LEFT SIDE (LOGO + MENU) */
.main-page-header-outer-left {
    display: flex;
    flex-direction: row;
    align-items: center;
}

.header-main-logo-link { line-height: 0; }
.header-main-logo-image { max-width: 15.3rem; }

/* Desktop Navigation (layout) */
.main-page-desktop-navigation ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    padding-left: 1.6rem;
}

.main-page-desktop-navigation ul li {
    border-right: 1px solid #6B6B6B;
     padding: 1.6rem 1.6rem;
}



.main-page-desktop-navigation ul li:last-child {
    border-right: none;
}

.main-page-desktop-navigation ul li a {
    font-size: 1.2rem;
    font-family: 'Open Sans', sans-serif;
    text-transform: uppercase;
    color: #FFF;
    text-decoration: none;
}

.main-page-desktop-navigation ul li a:hover,
.main-page-desktop-navigation ul li.current-menu-item a {
    text-decoration: underline;
}

/* RIGHT SIDE */
.main-page-header-outer-right {
    display: flex;
    align-items: center;
}

.header-main-cta {
    background-color: #C00038;
    font-weight: 800;
    font-size: 1.3rem;
    color: #FFF;
    padding: 0.4em 1.5em;
    border-radius: 100px;
    border-bottom: .3rem solid #6D0020;
    margin-right: .5rem;
    transition: transform .2s;
}
.header-main-cta:hover { transform: scale(1.05); }

/* ===== Language Switcher ===== */
.dropbtn {
    background-color: #101519;
    color: #FFF;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    padding: 0 0.5rem;
    height: 6rem;
    font-size: 1.2rem;
    text-transform: uppercase;
}
.dropbtn:hover, .openedlangmenu {
    background-color: #26353D;
}

.lang-switcher-icon {
    width: 3rem;
    height: 3rem;
    margin-right: 0.5rem;
}

.dropdown {
    position: relative;
}

.dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    min-width: 16rem;
    background: #26353D;
    z-index: 9999;
}

/* Prevent hidden overflow */
.main-page-header,
.main-page-header-wrapper,
.header-menu-container,
.main-page-desktop-navigation {
    overflow: visible !important;
}

/* =========================================================
   DESKTOP ONLY (≥ 992px)
========================================================= */
/* DESKTOP: Dodavanje strelice u glavnom meniju */
@media (min-width: 992px) {

	.main-page-desktop-navigation #menu-header-menu > li {
     padding: 2rem 1.6rem;
   
}


    .header-nav-desktop > li.menu-item-has-children {
        position: relative;
        padding-right: 20px; /* prostor za strelicu */
    }

    .header-nav-desktop > li.menu-item-has-children > a::after {
        content: "▾"; 
        position: absolute;
        right: 5px;
        top: 50%;
        transform: translateY(-50%);
        font-size: 12px;
        color: #ccc;
        pointer-events: none; 
    }

    
    .header-nav-desktop > li.menu-item-has-children:hover > a::after {
        color: #fff;
    } 
}







@media (min-width: 992px) {

    /* Enable desktop hover dropdowns */
    .header-nav-desktop > li {
        position: relative;
    }

    .header-nav-desktop .sub-menu {
        display: none !important;
        position: absolute !important;
        top: 100%;
        left: 0;
        min-width: 200px;
        background: #0F1418;
        border: 1px solid #2B2F33;
        padding: 0;
        z-index: 99999;
    }

    .header-nav-desktop > li:hover > .sub-menu {
        display: block !important;
    }

    .header-nav-desktop .sub-menu li a {
        padding: 10px 15px;
        color: #FFF;
        white-space: nowrap;
    }
}

/* =========================================================
   MOBILE (< 992px)
========================================================= */

.mobile-menu-toggler {
    display: none;
    cursor: pointer;
    margin-left: 1rem;
}
.bar {
    width: 30px;
    height: 3px;
    background: #FFF;
    margin: 6px 0;
    transition: transform .2s, opacity .2s;
}

/* Hamburger animation */
.cross #bar1 { transform: rotate(-45deg) translate(-5px, 6px); }
.cross #bar2 { opacity: 0; }
.cross #bar3 { transform: rotate(45deg) translate(-5px, -6px); }


@media (max-width: 991px) {

    /* Show hamburger */
    header.mobile-sizes .mobile-menu-toggler {
        display: inline-block;
    }

    /* Mobile menu container */
    header.mobile-sizes .main-page-desktop-navigation {
        position: fixed;
        top: 6rem;
        left: 100%;
        width: 100%;
        height: calc(100% - 6rem);
        background: #26353D;
        opacity: 0;
        transition: opacity .2s, left .2s;
        z-index: 999;
    }

    header.mobile-sizes .main-page-desktop-navigation.mobile-menu-opened {
        left: 0;
        opacity: 1;
    }

    /* Mobile UL */
    header.mobile-sizes .main-page-desktop-navigation ul {
        flex-direction: column;
        align-items: stretch;
    }

    header.mobile-sizes .main-page-desktop-navigation ul li {
        border: none;
        width: 100%;
        padding: 0;
    }

    header.mobile-sizes .main-page-desktop-navigation ul li > a {
        padding: 15px 20px;
        color: #FFF;
        font-size: 1.4rem;
        font-weight: 600;
        display: flex;
        justify-content: space-between;
        border-bottom: 1px solid rgba(255,255,255,0.15);
    }

    /* MOBILE SUBMENU (hidden by default) */
    /* Submenu container */
    .header-nav-desktop .sub-menu {
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        transform: translateY(-5px);
        transition:
            max-height 0.35s ease,
            opacity 0.25s ease,
            transform 0.25s ease;
    }

    /* When submenu is opened */
    .header-nav-desktop .sub-menu.open {
        max-height: 500px; /* dovoljno za 5–6 stavki */
        opacity: 1;
        transform: translateY(0);
    }

    .header-nav-desktop .sub-menu li a {
        padding: 12px 0;
        font-size: 1.3rem;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }

    /* Arrow icon */
    .submenu-toggle {
        font-size: 16px;
        margin-left: auto;
        cursor: pointer;
        transition: transform .2s;
    }
    .submenu-toggle.active {
        transform: rotate(90deg);
    }
}

/* MOBILE SUBMENU TOGGLE ARROW */
@media (max-width: 991px) {

    .submenu-toggle {
        font-size: 18px;
        color: #fff;
        padding: 10px;
        cursor: pointer;
        margin-left: auto;
        transition: transform 0.2s;
        user-select: none;
        position: absolute;
    	top: 0;
    	right: 20px;
    }

    .submenu-toggle.active {
        transform: rotate(180deg);
    }

    /* Parent menu item is flex row: text left + arrow right */
    .header-nav-desktop > li > a {
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
}


/* ============ MOBILE SUBMENU SLIDE (CSS ONLY) ============ */

@media (max-width: 991px) {

    /* Submenu container */
    .header-nav-desktop .sub-menu {
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        transform: translateY(-5px);
        transition:
            max-height 0.35s ease,
            opacity 0.25s ease,
            transform 0.25s ease;
    }

    /* When submenu is opened */
    .header-nav-desktop .sub-menu.open {
        max-height: 500px; /* dovoljno za 5–6 stavki */
        opacity: 1;
        transform: translateY(0);
    }

    /* Optional: arrow rotation */
    .submenu-toggle {
        transition: transform 0.25s ease;
    }
}

/* =========================================================
   PREMIUM MOBILE MENU — VISUAL IMPROVEMENTS
========================================================= */
@media (max-width: 991px) {

    /* Mobilni meni pozadina */
    header.mobile-sizes .main-page-desktop-navigation {
        background: rgba(16, 21, 25, 0.92); /* tamnije + transparencija */
        backdrop-filter: blur(6px); /* modern UI */
    }

    /* Glavne stavke */
    header.mobile-sizes .main-page-desktop-navigation ul li > a {
        padding: 12px 18px;
        font-size: 1.3rem;
        font-weight: 600;
        border-bottom: 1px solid rgba(255,255,255,0.07);
        letter-spacing: 0.5px;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    /* Submenu vizuelni stil */
    .header-nav-desktop .sub-menu {
        background: rgba(255,255,255,0.03);
        padding-left: 20px;
        border-left: 2px solid rgba(255,255,255,0.1);
        margin: 0 0 8px 0;
        border-radius: 4px;
    }

    /* Submenu stavke */
    .header-nav-desktop .sub-menu li a {
        padding: 10px 5px;
        font-size: 1.2rem;
        font-weight: 400;
        color: rgba(255,255,255,0.85);
        border-bottom: 1px solid rgba(255,255,255,0.05);
    }


    /* Submenu slide animacija */
    .header-nav-desktop .sub-menu {
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.35s ease, opacity 0.25s ease;
        opacity: 1;
    }
    .header-nav-desktop .sub-menu.open {
        max-height: 500px;
        opacity: 1;
    }

    /* Razmak između stavki (kompaktnije) */
    header.mobile-sizes .main-page-desktop-navigation ul li {
        margin-bottom: 2px;
    }
	#menu-header-menu li.menu-item-has-children > .sub-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

	#menu-header-menu li.menu-item-has-children.open > .sub-menu {
    	max-height: 500px; /* dovoljno za 5–10 linkova */
	}
	/* Osnovna strelica – mala crna */
.submenu-arrow {
    display: inline-block;
    margin-left: 6px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    padding: 2px;
    transform: rotate(45deg); /* strelica nadole */
    transition: transform 0.2s ease;
}

/* Kada je parent otvoren – rotacija nagore */
li.menu-item-has-children.open > a .submenu-arrow {
    transform: rotate(-135deg);
}

/* Submenu sakriven po defaultu */
#menu-header-menu li.menu-item-has-children > .sub-menu {
    display: none;
}

/* Prikaz submenua kada je otvoren */
#menu-header-menu li.menu-item-has-children.open > .sub-menu {
    display: block;
}


}



