/**
 * Mobil Alt Menü Çubuğu - Soft Modern CSS
 * Sadece mobil cihazlarda görünür
 */

 @media (max-width: 768px) {
    #mobile-bottom-bar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        background: var(--mbb-bar-bg, #f8f9fa);
        backdrop-filter: blur(20px) saturate(180%);
        -webkit-backdrop-filter: blur(20px) saturate(180%);
        border-top: 2px solid var(--mbb-bar-border, rgba(229, 231, 235, 0.8));
        box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.12), 
                    0 -2px 10px rgba(0, 0, 0, 0.08),
                    inset 0 1px 0 rgba(255, 255, 255, 0.9);
        display: flex;
        justify-content: space-around;
        align-items: center;
        padding: 5px;
        z-index: 9999;
        transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* Scroll down'da gizle (opsiyonel) */
    #mobile-bottom-bar.hidden {
        transform: translateY(100%);
    }

    .mobile-bottom-bar-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        flex: 1;
        padding: 10px 5px 0 5px;
        text-decoration: none;
        color: var(--mbb-item-color, #9ca3af);
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        position: relative;
        min-width: 0;
        -webkit-tap-highlight-color: transparent;
        border-radius: 12px;
        margin: 0 4px;
        opacity: 1;
    }

    .mobile-bottom-bar-item:active {
        transform: scale(0.92);
        background: var(--mbb-hover-bg, rgba(0, 109, 122, 0.05));
    }

    .mobile-bottom-bar-item.active {
        color: var(--mbb-item-active, #006d7a);
    }

    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon {
        transform: translateY(-2px);
    }

    .mobile-bottom-bar-icon {
        position: relative;
        width: var(--mbb-icon-box, 28px);
        height: var(--mbb-icon-box, 28px);
        display: flex;
        align-items: center;
        justify-content: center;
        margin-bottom: 6px;
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .mobile-bottom-bar-icon svg {
        width: var(--mbb-icon-svg, 24px);
        height: var(--mbb-icon-svg, 24px);
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* İkon container - transparent background */
    .mobile-bottom-bar-icon {
        background: transparent !important;
    }

    /* Pasif durum - ikon rengi */
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg {
        color: var(--mbb-inactive-icon, #808080) !important;
    }

    /* Pasif SVG elementleri - sadece çizgiler (stroke) */
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg path,
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg polyline,
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg line,
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg rect,
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg circle,
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg polygon {
        stroke: var(--mbb-inactive-icon, #808080) !important;
        fill: transparent !important;
    }

    /* Eğer SVG'de fill kullanılıyorsa (stroke yoksa) */
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg path[fill]:not([fill="none"]):not([stroke]),
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg rect[fill]:not([fill="none"]):not([stroke]),
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg circle[fill]:not([fill="none"]):not([stroke]),
    .mobile-bottom-bar-item .mobile-bottom-bar-icon svg polygon[fill]:not([fill="none"]):not([stroke]) {
        fill: var(--mbb-inactive-icon, #808080) !important;
        stroke: none !important;
    }

    /* Aktif durum - çizgiler */
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg {
        color: var(--mbb-item-active, #006d7a) !important;
        filter: drop-shadow(0 2px 6px rgba(0, 109, 122, 0.3));
        transform: scale(1.05);
    }

    /* Aktif SVG elementleri - sadece çizgiler */
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg path,
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg polyline,
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg line,
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg rect,
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg circle,
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg polygon {
        stroke: var(--mbb-item-active, #006d7a) !important;
        fill: transparent !important;
    }

    /* Aktif - fill kullananlar için */
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg path[fill]:not([fill="none"]):not([stroke]),
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg rect[fill]:not([fill="none"]):not([stroke]),
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg circle[fill]:not([fill="none"]):not([stroke]),
    .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg polygon[fill]:not([fill="none"]):not([stroke]) {
        fill: var(--mbb-item-active, #006d7a) !important;
        stroke: none !important;
    }

    .mobile-bottom-bar-label {
        font-size: var(--mbb-label-size, 11px);
        font-weight: 500;
        line-height: 1.3;
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 100%;
        transition: all 0.3s ease;
        letter-spacing: 0.2px;
    }

    .mobile-bottom-bar-item.active .mobile-bottom-bar-label {
        font-weight: 600;
        color: var(--mbb-item-active, #006d7a);
    }

    /* Sepet badge'i */
    .mobile-bottom-bar-badge {
        position: absolute;
        top: -4px;
        right: -6px;
        background: linear-gradient(135deg, var(--mbb-badge-1, #ff6b6b) 0%, var(--mbb-badge-2, #ee5a6f) 100%);
        color: #ffffff;
        font-size: 10px;
        font-weight: 700;
        line-height: 1.2;
        padding: 4px 7px;
        border-radius: 12px;
        min-width: 20px;
        text-align: center;
        box-shadow: 0 3px 12px rgba(255, 107, 107, 0.4);
        animation: badgePulse 2s ease-in-out infinite;
        border: 2px solid white;
    }

    @keyframes badgePulse {
        0%, 100% {
            transform: scale(1);
        }
        50% {
            transform: scale(1.1);
        }
    }

    /* Aktif durum göstergesi - main renk gradient */
    .mobile-bottom-bar-item.active::before {
        content: '';
        position: absolute;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 40px;
        height: 3px;
        background: linear-gradient(135deg, var(--mbb-grad-start, #006d7a) 0%, var(--mbb-grad-end, #00959f) 100%);
        border-radius: 0 0 8px 8px;
        box-shadow: 0 2px 8px rgba(0, 109, 122, 0.3);
    }

    /* Hover efekti - çizgiler #006d7a */
    .mobile-bottom-bar-item:not(.active):hover {
        color: var(--mbb-item-active, #006d7a);
        background: var(--mbb-hover-bg, rgba(0, 109, 122, 0.05));
    }

    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg {
        transform: scale(1.08);
        color: var(--mbb-item-active, #006d7a) !important;
    }

    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg path,
    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg polyline,
    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg line,
    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg rect,
    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg circle,
    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg polygon {
        stroke: var(--mbb-item-active, #006d7a) !important;
        fill: transparent !important;
    }

    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg path[fill]:not([fill="none"]):not([stroke]),
    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg rect[fill]:not([fill="none"]):not([stroke]),
    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg circle[fill]:not([fill="none"]):not([stroke]),
    .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg polygon[fill]:not([fill="none"]):not([stroke]) {
        fill: var(--mbb-item-active, #006d7a) !important;
        stroke: none !important;
    }

    /* Smooth transitions */
    .mobile-bottom-bar-item {
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* Dark mode desteği - ayarlardan kontrol edilir */
    #mobile-bottom-bar.dark-mode {
        background: var(--mbb-dark-bar, #1f2937);
        border-top: 2px solid rgba(0, 149, 159, 0.3);
        box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.3), 
                    0 -2px 10px rgba(0, 0, 0, 0.2),
                    inset 0 1px 0 rgba(255, 255, 255, 0.05);
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item {
        color: var(--mbb-dark-item, #a0aec0);
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg {
        color: var(--mbb-inactive-icon, #808080) !important;
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg path,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg polyline,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg line,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg rect,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg circle,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg polygon {
        stroke: var(--mbb-inactive-icon, #808080) !important;
        fill: transparent !important;
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg path[fill]:not([fill="none"]):not([stroke]),
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg rect[fill]:not([fill="none"]):not([stroke]),
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg circle[fill]:not([fill="none"]):not([stroke]),
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item .mobile-bottom-bar-icon svg polygon[fill]:not([fill="none"]):not([stroke]) {
        fill: var(--mbb-inactive-icon, #808080) !important;
        stroke: none !important;
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active {
        color: var(--mbb-dark-active, #4fd1c7);
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg {
        color: var(--mbb-dark-active, #4fd1c7) !important;
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg path,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg polyline,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg line,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg rect,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg circle,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg polygon {
        stroke: var(--mbb-dark-active, #4fd1c7) !important;
        fill: transparent !important;
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg path[fill]:not([fill="none"]):not([stroke]),
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg rect[fill]:not([fill="none"]):not([stroke]),
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg circle[fill]:not([fill="none"]):not([stroke]),
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-icon svg polygon[fill]:not([fill="none"]):not([stroke]) {
        fill: var(--mbb-dark-active, #4fd1c7) !important;
        stroke: none !important;
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg path,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg polyline,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg line,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg rect,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg circle,
    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item:not(.active):hover .mobile-bottom-bar-icon svg polygon {
        stroke: var(--mbb-dark-active, #4fd1c7) !important;
        fill: transparent !important;
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active::before {
        background: linear-gradient(135deg, var(--mbb-dark-grad-start, #4fd1c7) 0%, var(--mbb-dark-grad-end, #38b2ac) 100%);
    }

    #mobile-bottom-bar.dark-mode .mobile-bottom-bar-item.active .mobile-bottom-bar-label {
        color: var(--mbb-dark-active, #4fd1c7);
    }

    /* Tema .btn-canvas-search stilleri “seçili” gibi görünmesin (pasif çubuk renkleri) */
    #mobile-bottom-bar .mobile-bottom-bar-item.btn-canvas-search:not(.active) {
        color: var(--mbb-item-color, #9ca3af);
    }

    #mobile-bottom-bar .mobile-bottom-bar-item.btn-canvas-search:not(.active) .mobile-bottom-bar-icon svg {
        color: var(--mbb-inactive-icon, #808080) !important;
    }

    #mobile-bottom-bar .mobile-bottom-bar-item.btn-canvas-search:not(.active) .mobile-bottom-bar-icon svg path {
        stroke: var(--mbb-inactive-icon, #808080) !important;
    }

    #mobile-bottom-bar .mobile-bottom-bar-item.btn-canvas-account:not(.active) {
        color: var(--mbb-item-color, #9ca3af);
    }

    #mobile-bottom-bar .mobile-bottom-bar-item.btn-canvas-account:not(.active) .mobile-bottom-bar-icon svg {
        color: var(--mbb-inactive-icon, #808080) !important;
    }

    #mobile-bottom-bar .mobile-bottom-bar-item.btn-canvas-account:not(.active) .mobile-bottom-bar-icon svg path {
        stroke: var(--mbb-inactive-icon, #808080) !important;
    }

    /* Body padding - içerik bar'ın arkasında kalmasın */
    body {
        padding-bottom: var(--mbb-body-pad, 75px);
    }
}

/* Desktop'ta gizle */
@media (min-width: 769px) {
    #mobile-bottom-bar {
        display: none !important;
    }
}

/* SVG Gradient tanımlamaları */
.mobile-bottom-bar-gradient-defs {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
}
