.em-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: #149777;
    color: #fff;
    z-index: 10000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    overflow: visible;
}

.em-header-bar {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
    height: 72px;
    display: flex;
    align-items: center;
    gap: 14px;
}

.em-logo img {
    width: 150px;
    height: auto;
    display: block;
}

.em-search {
    flex: 1;
    min-width: 0;
    max-width: 560px;
    height: 40px;
    display: flex;
    position: relative;
    background: #fff;
    border-radius: 6px;
    overflow: visible;
}

.em-search input {
    flex: 1;
    min-width: 0;
    height: 40px;
    border: 0;
    outline: 0;
    padding: 0 14px;
    font-size: 14px;
    color: #333;
    border-radius: 6px 0 0 6px;
}

.em-search button {
    width: 46px;
    height: 40px;
    border: 0;
    background: #ff9800;
    color: #fff;
    cursor: pointer;
    border-radius: 0 6px 6px 0;
    font-size: 16px;
}

.em-search button:hover {
    background: #f57c00;
}

#searchResults {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    z-index: 1001;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 0 0 6px 6px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
    max-height: 360px;
    overflow: auto;
}

#searchResults.is-hidden,
.em-cart-count.is-hidden {
    display: none !important;
}

#searchResults a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    color: #222;
    text-decoration: none;
    font-size: 13px;
}

#searchResults a:hover {
    background: #f3faf7;
}

.em-no-results {
    padding: 12px;
    text-align: center;
    color: #666;
    font-size: 13px;
}

.em-cart {
    position: relative;
    color: #fff;
    font-size: 22px;
    text-decoration: none;
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.em-cart-count {
    position: absolute;
    top: 2px;
    right: 0;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    background: #e53935;
    color: #fff;
    font-size: 11px;
    line-height: 18px;
    text-align: center;
    border-radius: 9px;
}

.em-nav {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
}

.em-nav a i {
    margin-right: 6px;
}

.em-nav a,
.em-drop summary {
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    padding: 8px 10px;
    border-radius: 6px;
    white-space: nowrap;
    cursor: pointer;
    list-style: none;
}

.em-nav a:hover,
.em-drop summary:hover {
    background: rgba(255, 255, 255, 0.14);
}

.em-drop summary::-webkit-details-marker {
    display: none;
}

.em-drop {
    position: relative;
}

.em-drop-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 220px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    padding: 6px;
    z-index: 1002;
}

.em-drop[open] .em-drop-menu {
    display: block;
}

.em-drop-menu a {
    display: block;
    color: #222 !important;
    padding: 8px 10px;
    border-radius: 6px;
}

.em-drop-menu a:hover {
    background: #f3faf7 !important;
}

.em-caret {
    margin-left: 4px;
    font-size: 10px;
    opacity: 0.85;
}

.em-mega {
    position: fixed;
    top: 66px;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: 820px;
    max-width: calc(100vw - 32px);
    min-height: 340px;
    padding: 8px;
    font-family: "Segoe UI", Arial, sans-serif;
    font-size: 13px;
    white-space: normal;
}

.em-mega-empty {
    padding: 14px;
    color: #6b7280;
}

.em-cat-list {
    list-style: none;
    margin: 0;
    padding: 0 8px 0 0;
    width: 240px;
    border-right: 1px solid #eef2f1;
    min-height: 324px;
}

.em-cat-link {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 9px 12px !important;
    font-size: 13px !important;
    font-weight: 600;
    white-space: normal !important;
}

.em-cat-link i {
    margin: 0 !important;
    font-size: 10px;
    color: #9ca3af;
}

.em-cat-panel {
    display: none;
    position: absolute;
    top: 8px;
    left: 256px;
    right: 8px;
    bottom: 8px;
    padding: 6px 8px 8px 12px;
    overflow-y: auto;
}

.em-cat:hover > .em-cat-panel,
.em-cat:focus-within > .em-cat-panel,
.em-cat-list:not(:hover) > .em-cat:first-child > .em-cat-panel {
    display: block;
}

.em-cat:hover > .em-cat-link,
.em-cat:focus-within > .em-cat-link,
.em-cat-list:not(:hover) > .em-cat:first-child > .em-cat-link {
    background: #e8f7f1 !important;
    color: #0f7a61 !important;
}

.em-cat:hover > .em-cat-link i,
.em-cat-list:not(:hover) > .em-cat:first-child > .em-cat-link i {
    color: #149777;
}

.em-panel-title {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
    padding: 6px 10px !important;
    color: #149777 !important;
    font-size: 14px;
    font-weight: 700;
}

.em-panel-title i {
    margin: 0 !important;
    font-size: 11px;
}

.em-sub-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px 18px;
}

.em-sub {
    padding-bottom: 8px;
}

.em-sub-link {
    padding: 6px 10px !important;
    font-weight: 700;
    color: #145c4b !important;
    border-bottom: 1px solid #eef2f1;
    border-radius: 6px 6px 0 0 !important;
    white-space: normal !important;
}

.em-prod-link {
    padding: 5px 10px !important;
    color: #4b5563 !important;
    font-size: 13px !important;
    white-space: normal !important;
}

.em-prod-link:hover {
    color: #f57224 !important;
}

.em-menu-btn {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    background: transparent;
    color: #fff;
    font-size: 22px;
    cursor: pointer;
}

body {
    padding-top: 72px;
}

@media (max-width: 900px) {
    .em-menu-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .em-header-bar {
        height: auto;
        flex-wrap: wrap;
        padding-top: 8px;
        padding-bottom: 8px;
    }

    .em-logo img {
        width: 120px;
    }

    .em-search {
        order: 5;
        flex: 1 1 100%;
        max-width: none;
    }

    .em-nav {
        display: none;
        order: 6;
        flex: 1 1 100%;
        flex-direction: column;
        align-items: stretch;
        margin-left: 0;
        padding-bottom: 8px;
    }

    .em-nav.is-open {
        display: flex;
    }

    .em-drop-menu {
        position: static;
        box-shadow: none;
        background: rgba(255, 255, 255, 0.96);
        min-width: 0;
    }

    .em-mega {
        position: static;
        transform: none;
        width: auto;
        max-width: none;
        min-height: 0;
    }

    .em-cat-list {
        width: auto;
        min-height: 0;
        padding: 0;
        border-right: 0;
    }

    .em-cat-panel,
    .em-cat-list:not(:hover) > .em-cat:first-child > .em-cat-panel {
        display: none;
        position: static;
        padding: 0 0 8px 12px;
    }

    .em-cat:hover > .em-cat-panel,
    .em-cat:focus-within > .em-cat-panel {
        display: block;
    }

    .em-sub-grid {
        grid-template-columns: 1fr;
    }

    body {
        padding-top: 116px;
    }

    .sidebar {
        top: 116px;
        height: calc(100vh - 116px);
    }
}
