/**
 * Washin Auto - Modern Custom Header Styles
 */

:root {
    --primary-color: var(--main-color);
    --primary-dark: #005d96;
    --primary-light: #e6f3ff;
    --accent-color: #ff6b35;
    --text-dark: #1a1a2e;
    --text-medium: #4a4a68;
    --text-light: #6e7191;
    --bg-light: #f8f9fa;
    --bg-dark: #16213e;
    --white: #ffffff;
    --black: #000000;
    --border-radius-sm: 8px;
    --border-radius-md: 12px;
    --border-radius-lg: 20px;
    --border-radius-xl: 30px;
    --box-shadow-sm: 0 5px 15px rgba(0, 0, 0, 0.05);
    --box-shadow-md: 0 10px 30px rgba(0, 0, 0, 0.1);
    --box-shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.1);
    --transition-fast: all 0.3s ease;
    --transition-medium: all 0.5s ease;
    --transition-slow: all 0.8s ease;
    --font-primary: "Noto Sans", sans-serif;
    --font-secondary: "Oswald", sans-serif;
}

/* Preloader */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.preloader.loaded {
    opacity: 0;
    visibility: hidden;
}

.loader {
    position: relative;
    width: 80px;
    height: 80px;
}

.loader svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

#loader-circle {
    fill: none;
    stroke: var(--primary-color);
    stroke-width: 4;
    stroke-dasharray: 200;
    stroke-dashoffset: 200;
    animation: loader-circle 2s linear infinite;
}

.car-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 24px;
    color: var(--primary-color);
    animation: car-bounce 1s ease-in-out infinite alternate;
}

@keyframes loader-circle {
    0% {
        stroke-dashoffset: 200;
    }

    50% {
        stroke-dashoffset: 0;
    }

    100% {
        stroke-dashoffset: -200;
    }
}

@keyframes car-bounce {
    0% {
        transform: translate(-50%, -50%) scale(1);
    }

    100% {
        transform: translate(-50%, -50%) scale(1.2);
    }
}

/* Top Bar */
.top-bar {
    background-color: var(--primary-dark);
    padding: 10px 0;
    color: var(--white);
    font-size: 14px;
}

.top-bar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar-info {
    display: flex;
    gap: 20px;
}

.info-item {
    font-size: 12px;
    letter-spacing: .25px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--white) !important;
}

.info-item i {
    color: rgba(255, 255, 255, 0.7);
}

.top-bar-social {
    display: flex;
    gap: 15px;
}

.social-icon {
    color: rgba(255, 255, 255, 0.7);
    transition: var(--transition-fast);
}

.social-icon:hover {
    color: var(--white);
    transform: translateY(-3px);
}

/* Header */
.site-header {
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--white);
    z-index: 100;
    transition: var(--transition-fast);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
}

.site-header.transparent {
    position: absolute;
    top: 0;
    left: 0;
    background-color: transparent;
    box-shadow: none;
}

.site-header.transparent .header-inner {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.site-header.transparent .menu-item > a {
    color: var(--white);
}

.site-header.transparent .action-item {
    color: var(--white);
}

.site-header.transparent .logo-light {
    display: block;
}

.site-header.transparent .logo-dark {
    display: none;
}

.site-header.sticky {
    position: fixed;
    top: 0;
    left: 0;
    background-color: var(--white);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    animation: slideDown 0.5s ease;
}

.site-header.sticky .header-inner {
    padding: 15px 0;
}

.site-header.sticky .menu-item > a {
    color: var(--text-dark);
}

.site-header.sticky .action-item {
    color: var(--text-dark);
}

.site-header.sticky .logo-light {
    /*display: none;*/
}

.site-header.sticky .logo-dark {
    display: block;
}

@keyframes slideDown {
    from {
        transform: translateY(-100%);
    }

    to {
        transform: translateY(0);
    }
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    transition: var(--transition-fast);
}

.logo-wrapper {
    flex: 0 0 auto;
}

.logo img {
    height: 50px;
    transition: var(--transition-fast);
}

.logo-light {}

.navigation-wrapper {
    flex: 1;
    display: flex;
    justify-content: center;
}

.main-navigation {
    position: relative;
}

.menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.menu-item {
    position: relative;
    margin: 0 5px;
}

.menu-item > a {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    color: #333;
    font-weight: 500;
    text-decoration: none;
    transition: var(--transition-fast);
    position: relative;
}

.menu-item > a:before {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background-color: var(--primary-color);
    transition: var(--transition-fast);
    border-radius: 3px;
}

.menu-item:hover > a:before,
.menu-item.active > a:before {
    width: 30px;
}

.menu-item:hover > a,
.menu-item.active > a {
    color: var(--primary-color);
}

.menu-item > a i {
    font-size: 12px;
    margin-left: 5px;
    transition: var(--transition-fast);
}

.menu-item:hover > a i {
    transform: rotate(180deg);
}

.menu-item-has-children:hover .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background-color: var(--white);
    border-radius: var(--border-radius-md);
    box-shadow: var(--box-shadow-md);
    padding: 15px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: var(--transition-fast);
    z-index: 10;
}

.sub-menu:before {
    content: "";
    position: absolute;
    top: -10px;
    left: 30px;
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 10px solid var(--white);
}

.sub-menu li {
    list-style: none;
}

.sub-menu li a {
    display: block;
    padding: 8px 25px;
    color: var(--text-medium);
    font-weight: 500;
    text-decoration: none;
    transition: var(--transition-fast);
}

.sub-menu li a:hover {
    color: var(--primary-color);
    background-color: rgba(0, 114, 186, 0.05);
    padding-left: 30px;
}

.header-actions {
    display: flex;
    align-items: center;
}

.action-item {
    position: relative;
    color: var(--text-dark);
    font-size: 18px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.action-item:hover {
    color: var(--primary-color);
}

.wishlist-btn .count {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 18px;
    height: 18px;
    background-color: var(--primary-color);
    color: var(--white);
    font-size: 10px;
    font-weight: 700;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.action-item .user-btn{
    margin-left: 20px;
}

.action-item .user-btn img {
    border: 1px solid #0072BA;
    border-radius: 5px;
    background-color: #f8f9fa;
}

.language-selector {
    position: relative;
}

.selected-language {
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    font-size: 14px;
}

.selected-language img {
    height: 15px;
    object-fit: cover;
    border: 1px solid #e1e1e1;
}

.selected-language i {
    font-size: 12px;
    transition: var(--transition-fast);
}

.language-selector:hover .selected-language i {
    transform: rotate(180deg);
}

.language-selector:hover .language-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.language-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 150px;
    background-color: var(--white);
    border-radius: var(--border-radius-md);
    box-shadow: var(--box-shadow-md);
    padding: 10px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: var(--transition-fast);
    z-index: 10;
}

.language-dropdown:before {
    content: "";
    position: absolute;
    top: -10px;
    right: 20px;
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 10px solid var(--white);
}

.language-dropdown li {
    list-style: none;
}

.language-dropdown li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 15px;
    color: var(--text-medium);
    text-decoration: none;
    transition: var(--transition-fast);
    font-size: 12px;
}

.language-dropdown li a:hover {
    background-color: rgba(0, 114, 186, 0.05);
}

.language-dropdown li a img {
    height: 15px;
    object-fit: cover;
    border: 1px solid #e1e1e1;
}

.mobile-menu-toggle {
}

.hamburger-menu {    
    margin-left: 10px;
    display: none;
    cursor: pointer;
    background: #e6f3ff;
    padding: 1.5px 6px;
    border-radius: 5px;
    position: relative;
}

.hamburger-menu span {
    display: block;
    position: absolute;
    height: 2px;
    width: 100%;
    background-color: var(--text-dark);
    border-radius: 3px;
    transition: var(--transition-fast);
}

.hamburger-menu span:nth-child(1) {
    top: 0;
}

.hamburger-menu span:nth-child(2) {
    top: 6px;
}

.hamburger-menu span:nth-child(3) {
    top: 12px;
}

.site-header.transparent .hamburger-menu span {
    background-color: var(--white);
}

/* Mobile Menu */
.mobile-menu-container {
    position: fixed;
    top: 0;
    right: -100%;
    width: 300px;
    height: 100%;
    background-color: var(--white);
    z-index: 999;
    overflow-y: auto;
    transition: var(--transition-medium);
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.1);
}

.mobile-menu-container.active {
    right: 0;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
}

.mobile-menu-header .logo img {
    height: 40px;
}

.mobile-menu-close {
    font-size: 24px;
    color: var(--text-dark);
    cursor: pointer;
    transition: var(--transition-fast);
}

.mobile-menu-close:hover {
    color: var(--primary-color);
    transform: rotate(90deg);
}

.mobile-menu-content {
    padding: 20px;
}

.mobile-search {
    margin-bottom: 20px;
}

.mobile-search form {
    position: relative;
}

.mobile-search input {
    width: 100%;
    height: 50px;
    padding: 0 20px;
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius-md);
    font-size: 16px;
    color: var(--text-dark);
    background-color: var(--bg-light);
    transition: var(--transition-fast);
}

.mobile-search input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 114, 186, 0.1);
}

.mobile-search button {
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--text-light);
    font-size: 18px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.mobile-search button:hover {
    color: var(--primary-color);
}

.mobile-navigation {
    margin-bottom: 30px;
}

.mobile-menu {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-menu-item {
    border-bottom: 1px solid #e9ecef;
}

.mobile-menu-item > a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    color: var(--text-dark);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition-fast);
}

.mobile-menu-item.active > a {
    color: var(--primary-color);
}

.dropdown-toggle {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.mobile-menu-item-has-children.active .dropdown-toggle i {
    transform: rotate(180deg);
}

.mobile-sub-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: none;
    background-color: var(--bg-light);
    border-radius: var(--border-radius-md);
    overflow: hidden;
    margin-bottom: 15px;
}

.mobile-menu-item-has-children.active .mobile-sub-menu {
    display: block;
}

.mobile-sub-menu li a {
    display: block;
    padding: 12px 15px;
    color: var(--text-medium);
    font-weight: 500;
    text-decoration: none;
    transition: var(--transition-fast);
}

.mobile-sub-menu li a:hover {
    color: var(--primary-color);
    background-color: rgba(0, 114, 186, 0.05);
    padding-left: 20px;
}

.mobile-contact-info {
    margin-bottom: 30px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    color: var(--text-medium);
}

.contact-item i {
    width: 40px;
    height: 40px;
    background-color: rgba(0, 114, 186, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
}

.mobile-social {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.mobile-social .social-icon {
    width: 40px;
    height: 40px;
    background-color: var(--bg-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-medium);
    transition: var(--transition-fast);
}

.mobile-social .social-icon:hover {
    background-color: var(--primary-color);
    color: var(--white);
    transform: translateY(-3px);
}

.mobile-language {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.language-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 15px;
    background-color: var(--bg-light);
    border-radius: var(--border-radius-md);
    color: var(--text-medium);
    text-decoration: none;
    transition: var(--transition-fast);
}

.language-item.active {
    background-color: var(--primary-color);
    color: var(--white);
}

.language-item img {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    object-fit: cover;
}

/* Search Overlay */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-medium);
}

.search-overlay.active {
    opacity: 1;
    visibility: visible;
}

.search-overlay-close {
    position: absolute;
    top: 30px;
    right: 30px;
    font-size: 30px;
    color: var(--white);
    cursor: pointer;
    transition: var(--transition-fast);
}

.search-overlay-close:hover {
    color: var(--primary-color);
    transform: rotate(90deg);
}

.search-overlay-content {
    width: 100%;
    max-width: 700px;
    padding: 0 20px;
}

.search-overlay-content form {
    text-align: center;
}

.search-overlay-content h3 {
    color: var(--white);
    font-size: 36px;
    margin-bottom: 30px;
}

header .search-input {
    position: relative;
    margin-bottom: 30px;
}

header .search-input input {
    width: 100%;
    height: 70px;
    padding: 0 30px;
    border: none;
    border-radius: var(--border-radius-xl);
    font-size: 18px;
    color: var(--text-dark);
    background-color: var(--white);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: var(--transition-fast);
}

header .search-input input:focus {
    outline: none;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

header .search-input button {
    position: absolute;
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
    background-color: var(--primary-color);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    color: var(--white);
    font-size: 20px;
    cursor: pointer;
    transition: var(--transition-fast);
}

header .search-input button:hover {
    background-color: var(--primary-dark);
    box-shadow: 0 5px 15px rgba(0, 114, 186, 0.3);
}

.popular-searches {
    color: var(--white);
}

.popular-searches span {
    margin-right: 15px;
    opacity: 0.7;
}

.popular-searches a {
    display: inline-block;
    margin: 5px;
    padding: 8px 15px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius-md);
    color: var(--white);
    text-decoration: none;
    transition: var(--transition-fast);
}

.popular-searches a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

/* Responsive Styles */
@media (max-width: 1199.98px) {
    .menu-item > a {
        padding: 10px 12px;
    }
}

@media (max-width: 991.98px) {
    .navigation-wrapper {
        display: none;
    }

    .hamburger-menu {
        display: block;
    }

    .header-actions {
        gap: 15px;
    }

    .action-item.search-toggle,
    .action-item.wishlist-btn,
    .action-item.user-btn {
        display: none;
    }
}

@media (max-width: 767.98px) {
    .top-bar {
        display: none;
    }

    .header-inner {
        padding: 15px 0;
    }

    .logo img {
        height: 40px;
    }

    .search-overlay-close {
        top: 20px;
        right: 20px;
    }

    .search-overlay-content h3 {
        font-size: 28px;
    }

    header .search-input input {
        height: 60px;
        font-size: 16px;
    }
}

@media (max-width: 575.98px) {
    .mobile-menu-container {
        width: 100%;
    }

    .search-overlay-content h3 {
        font-size: 24px;
    }

    .popular-searches span {
        display: block;
        margin-bottom: 10px;
    }
}
