/*
Theme Name: Concepte Autoaparare
Theme URI: https://concepteautoaparare.ro
Author: Concepte Autoaparare Team
Author URI: https://concepteautoaparare.ro
Description: Tema WordPress pentru Concepte Autoaparare
Version: 1.0.1
License: GPL v2 or later
Text Domain: concepte-autoaparare
*/

/* ==========================================================================
   HERO IMAGE FIX - Poziționare imagine pentru a vedea personajele
   ========================================================================== */

/* Imaginea hero pe pagina principală - arată partea stângă */
.jarallax-img,
.jarallax > img {
    object-position: left center !important;
}

/* Pentru desktop - mai mult la stânga */
@media only screen and (min-width: 992px) {
    .jarallax-img,
    .jarallax > img {
        object-position: 20% center !important;
    }
}

/* Pentru mobile - la DREAPTA pentru a vedea personajele */
@media only screen and (max-width: 991px) {
    .jarallax-img,
    .jarallax > img {
        object-position: 100% center !important;
    }
}

/* Pentru telefoane mici - complet la dreapta */
@media only screen and (max-width: 576px) {
    .jarallax-img,
    .jarallax > img {
        object-position: 100% center !important;
    }
}

/* Overlay pentru lizibilitatea textului pe mobile */
@media only screen and (max-width: 991px) {
    section.jarallax::before,
    section.relative.jarallax::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.6);
        z-index: 1;
        pointer-events: none;
    }
}

/* ==========================================================================
   FIX - group_picture2 să nu acopere textul pe mobile
   ========================================================================== */

@media only screen and (max-width: 991px) {
    /* Elimină poziționarea absolută pe mobile */
    .rounded-1.w-50.abs.mb-min-50 {
        position: relative !important;
        width: 100% !important;
        margin-bottom: 0 !important;
        margin-top: 20px !important;
    }

    /* Sau ascunde complet imaginea mică pe mobile */
    /* .rounded-1.w-50.abs.mb-min-50 {
        display: none !important;
    } */
}

/* ==========================================================================
   LOGO FIX - Proper sizing and aspect ratio
   ========================================================================== */

#logo img {
    max-width: 80px !important;
    height: auto !important;
    object-fit: contain !important;
    width: auto !important;
}

#logo img.logo-main,
#logo img.logo-scroll,
#logo img.logo-mobile {
    max-width: 80px !important;
    height: auto !important;
    object-fit: contain !important;
}

/* ==========================================================================
   MEGA MENU / SUBMENU FIX - Hide by default
   ========================================================================== */

/* Hide all submenus and mega menus by default */
#mainmenu ul,
#mainmenu .mega,
#mainmenu li ul,
#mainmenu li .mega,
#mainmenu > li > ul,
#mainmenu > li > .mega,
.mega-menu,
.sub-menu {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    position: absolute !important;
}

/* Show submenu only on hover (desktop) */
@media only screen and (min-width: 993px) {
    #mainmenu li:hover > ul,
    #mainmenu li:hover > .mega,
    #mainmenu > li:hover > ul,
    #mainmenu > li:hover > .mega {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        pointer-events: auto !important;
    }
}

/* ==========================================================================
   MOBILE MENU FIX - Hide until hamburger is clicked
   ========================================================================== */

@media only screen and (max-width: 992px) {
    /* Ensure header has solid dark background on mobile */
    header,
    header.transparent,
    header.header-mobile {
        background: #111 !important;
    }

    /* Hide main menu by default on mobile */
    #mainmenu {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        position: absolute !important;
        top: 100%;
        left: 0;
        right: 0;
        background: #111 !important;
        z-index: 1000;
    }

    /* Show mobile menu when header has menu-open or show class */
    header.menu-open #mainmenu,
    header.header-mobile.menu-open #mainmenu,
    header.show #mainmenu,
    header.header-mobile.show #mainmenu,
    .header-mobile.menu-show #mainmenu {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    /* Ensure logo is visible and properly sized */
    header #logo {
        position: relative;
        z-index: 1001;
    }

    header #logo img {
        position: relative;
        z-index: 1001;
        max-height: 60px !important;
        width: auto !important;
        max-width: 70px !important;
    }

    /* Ensure menu button (hamburger) is visible and styled */
    #menu-btn {
        display: block !important;
        z-index: 1002;
        color: #fff !important;
        cursor: pointer;
    }

    /* Hide the join button on mobile */
    header .btn-main {
        display: none !important;
    }

    /* Style the mobile menu when open */
    header.header-mobile #mainmenu li {
        border-color: #333 !important;
        display: block !important;
        width: 100%;
    }

    header.header-mobile #mainmenu a {
        color: #fff !important;
    }

    /* Hide submenu indicators on mobile */
    #mainmenu .has-child:after,
    #mainmenu li.has-child > a:after {
        display: none !important;
    }
}

/* Smaller mobile screens */
@media only screen and (max-width: 767px) {
    header #logo img.logo-mobile {
        display: block !important;
        max-height: 50px !important;
        max-width: 60px !important;
    }

    header #logo img.logo-main,
    header #logo img.logo-scroll {
        display: none !important;
    }
}

/* ==========================================================================
   WordPress Specific Styles
   ========================================================================== */

.wp-block-separator {
    border: 0;
    border-top: 2px solid #ccc;
    margin: 2em 0;
}

.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.alignleft {
    float: left;
    margin-right: 1.5em;
}

.alignright {
    float: right;
    margin-left: 1.5em;
}

.wp-caption {
    max-width: 100%;
}

.wp-caption img {
    display: block;
    margin: 0 auto;
}

.wp-caption-text {
    text-align: center;
    margin-top: 0.5em;
}

.sticky {
    position: relative;
}

.gallery-caption {
    display: block;
}

.bypostauthor {
    font-weight: bold;
}

/* WordPress menu fix */
#mainmenu {
    list-style: none;
    margin: 0;
    padding: 0;
}

#mainmenu li {
    display: inline-block;
}

#mainmenu a {
    text-decoration: none;
}
