/* ===========================================
   Ambitemp Navbar Icons v1.1.3
   =========================================== */

/* Keep the header navigation hover aligned with the blue brand bar. */
.elementor-widget-navigation-menu .menu-item > a.hfe-menu-item:hover,
.elementor-widget-navigation-menu .menu-item > a.hfe-menu-item:focus,
.elementor-widget-navigation-menu .sub-menu a.hfe-sub-menu-item:hover,
.elementor-widget-navigation-menu .sub-menu a.hfe-sub-menu-item:focus {
    color: #3395c6 !important;
}

/* === ÍCONES CONTAINER === */
/* Slightly reduce the verified blue header bar, retaining its native layout. */
#masthead .elementor-element.elementor-element-1c54c62 {
    padding-top: 6px !important;
    padding-bottom: 6px !important;
}

/* HFE rounds the menu width after resizing; retain one desktop row. */
@media (min-width: 1025px) {
    #masthead .elementor-element-4c845d5 .hfe-nav-menu__layout-horizontal > .hfe-nav-menu {
        flex-wrap: nowrap;
    }
}

.amb-nav-icons {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
}

/* === CADA ÍCONE — forçar branco sobre qualquer tema === */
.amb-nav-icons .amb-ni,
.amb-nav-icons .amb-ni:link,
.amb-nav-icons .amb-ni:visited,
.amb-nav-icons .amb-ni:hover,
.amb-nav-icons .amb-ni:focus,
.amb-nav-icons .amb-ni:active,
.amb-nav-icons a.amb-ni,
a.amb-ni {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 36px !important;
    height: 36px !important;
    color: #ffffff !important;
    text-decoration: none !important;
    position: relative !important;
    border-radius: 50% !important;
    transition: opacity 0.2s !important;
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    outline: none !important;
}
.amb-nav-icons .amb-ni:hover {
    opacity: 0.75 !important;
}

/* SVGs */
.amb-nav-icons .amb-ni svg,
.amb-ni svg {
    display: block !important;
    width: 22px !important;
    height: 22px !important;
    color: inherit !important;
    fill: none !important;
    pointer-events: none !important;
}

/* === BADGE CARRINHO === */
.amb-ni-badge {
    position: absolute !important;
    top: 0 !important;
    right: -4px !important;
    min-width: 18px !important;
    height: 18px !important;
    background: #e74c3c !important;
    color: #fff !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    line-height: 18px !important;
    text-align: center !important;
    border-radius: 9px !important;
    padding: 0 4px !important;
    font-family: -apple-system, BlinkMacSystemFont, sans-serif !important;
}

/* === DOT LOGGED IN (user icon) === */
.amb-ni-dot {
    position: absolute !important;
    bottom: 4px !important;
    right: 4px !important;
    width: 8px !important;
    height: 8px !important;
    background: #27ae60 !important;
    border: 2px solid #4aafe0 !important;
    border-radius: 50% !important;
    pointer-events: none !important;
}

/* ===========================================
   MINI-CART POPUP
   =========================================== */
.amb-minicart {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    width: 360px;
    height: 100vh;
    z-index: 99999;
    pointer-events: none;
}
.amb-minicart.is-open {
    display: block;
    pointer-events: auto;
}

.amb-minicart-inner {
    position: absolute;
    top: 0;
    right: -380px;
    width: 360px;
    height: 100%;
    background: #fff;
    box-shadow: -4px 0 24px rgba(0,0,0,0.12);
    display: flex;
    flex-direction: column;
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}
.amb-minicart.is-open .amb-minicart-inner {
    right: 0;
}

/* Header */
.amb-minicart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #eee;
    flex-shrink: 0;
}
.amb-minicart-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
}
.amb-minicart-close {
    font-size: 24px;
    color: #999;
    cursor: pointer;
    line-height: 1;
    padding: 0 4px;
    transition: color 0.15s;
}
.amb-minicart-close:hover {
    color: #333;
}

/* Items */
.amb-minicart-items {
    flex: 1;
    overflow-y: auto;
    padding: 12px 20px;
}

.amb-minicart-empty {
    padding: 40px 0;
    text-align: center;
    color: #999;
    font-size: 14px;
}

.amb-mc-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #f2f2f2;
}
.amb-mc-item:last-child {
    border-bottom: none;
}

.amb-mc-item-img {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    border-radius: 6px;
    overflow: hidden;
    background: #f5f5f5;
}
.amb-mc-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.amb-mc-item-info {
    flex: 1;
    min-width: 0;
}
.amb-mc-item-name {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.amb-mc-item-meta {
    display: block;
    font-size: 12px;
    color: #888;
    margin-top: 4px;
}

.amb-mc-item-remove {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: #ccc !important;
    text-decoration: none !important;
    border-radius: 50%;
    transition: all 0.15s;
}
.amb-mc-item-remove:hover {
    color: #e74c3c !important;
    background: #fef2f2;
}

/* Footer */
.amb-minicart-footer {
    flex-shrink: 0;
    padding: 16px 20px;
    border-top: 1px solid #eee;
}

.amb-minicart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    font-size: 14px;
    color: #333;
}
.amb-minicart-total strong {
    font-size: 16px;
}

.amb-minicart-actions {
    display: flex;
    gap: 10px;
}

.amb-mc-btn {
    flex: 1;
    display: block;
    text-align: center;
    padding: 10px 16px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 6px;
    text-decoration: none !important;
    transition: all 0.15s;
    cursor: pointer;
}
.amb-mc-btn--outline {
    border: 1px solid #ddd;
    color: #333 !important;
    background: #fff;
}
.amb-mc-btn--outline:hover {
    border-color: #bbb;
    background: #f9f9f9;
}
.amb-mc-btn--fill {
    border: 1px solid #4aafe0;
    color: #fff !important;
    background: #4aafe0;
}
.amb-mc-btn--fill:hover {
    background: #3a9fd0;
    border-color: #3a9fd0;
}

/* Overlay */
.amb-minicart-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.3);
    z-index: 99998;
}
.amb-minicart-overlay.is-open {
    display: block;
}

/* Scrollbar */
.amb-minicart-items::-webkit-scrollbar {
    width: 4px;
}
.amb-minicart-items::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 2px;
}

/* Responsive */
@media (max-width: 480px) {
    .amb-minicart {
        width: 100%;
    }
    .amb-minicart-inner {
        width: 100%;
        right: -100%;
    }
}


/* Centre the existing logo and icon group on phone layouts. */
@media (max-width: 767px) {
    #masthead .elementor-element-2928880 {
        display: grid !important;
        grid-template-columns: 36px minmax(0, 1fr) 36px;
        gap: 0 12px !important;
        align-items: center !important;
        min-height: 70px;
    }
    #masthead .elementor-element-2928880 > .elementor-element-3b51288 {
        grid-column: 1;
        grid-row: 1;
        justify-self: start;
        margin: 0 !important;
    }
    #masthead .elementor-element-2928880 > .elementor-element-0f6f3f0 {
        grid-column: 2;
        grid-row: 1;
        justify-self: center;
        width: 200px !important;
        max-width: 100% !important;
        margin: 0 !important;
    }
    #masthead .elementor-element-c358c50 > .elementor-element-5d1af59 {
        align-self: center !important;
        margin-inline: auto !important;
    }
    #masthead .amb-nav-icons {
        justify-content: center;
    }
}
