﻿.search-link {
    color: #000000 !important;
    opacity: 1 !important;
    font-size: 23px;
}

.search-container {
    position: relative;
    display: flex;
    align-items: center;
    width: 45px;
    transition: width 0.4s ease;
    overflow: hidden;
}

    .search-container:hover {
        width: 230px;
    }

.search-input {
    width: 100%;
    border: 1px solid #ddd;
    outline: none;
    padding: 8px 45px 8px 15px;
    border-radius: 999px;
    opacity: 0;
    transition: opacity 0.3s ease;
    background-color: #fff;
}

.search-container:hover .search-input {
    opacity: 1;
}

.search-btn {
    position: absolute;
    right: 0;
    width: 45px;
    height: 45px;
    border: none;
    background: transparent;
    cursor: pointer;
}

    .search-btn i {
        font-size: 24px;
        color: #000000;
    }

    .search-btn:hover i {
        color: #000000;
    }

.cart-link i,
.login-link i {
    font-size: 26px;
    color: #000000 !important;
    transition: all 0.2s ease;
}

.cart-link:hover i,
.login-link:hover i {
    color: #000000 !important;
    transform: scale(1.08);
}

.search-results {
    position: absolute;
    top: 45px;
    right: 0;
    width: 300px;
    background: white;
    border: 1px solid #eee;
    border-radius: 10px;
    box-shadow: 0 8px 18px rgba(0,0,0,0.08);
    display: none;
    z-index: 999;
}

.search-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    text-decoration: none;
    color: #333;
    border-bottom: 1px solid #f2f2f2;
}

    .search-item:hover {
        background: #f7f7f7;
    }

    .search-item img {
        width: 40px;
        height: 40px;
        object-fit: contain;
    }

.search-name {
    font-size: 14px;
    font-weight: 600;
}

.search-price {
    font-size: 12px;
    color: #198754;
}

/* NAVBAR MODERN GEÇİŞ */

.custom-navbar {
    background: linear-gradient( to bottom, #ffffff 0%, #ffffff 65%, #eef7fc 85%, #d9edf7 100% );
}

/* navbar altındaki sert çizgiyi kaldır */
.navbar {
    border-bottom: none;
}

/* navbar ile sayfa birleşimini daha modern yapmak için */
.custom-navbar::after {
    content: "";
    display: block;
    height: 20px;
    background: linear-gradient( to bottom, rgba(255,255,255,0.3), rgba(217,237,247,0.8), #d9edf7 );
}

/* MOBİL NAVBAR İKONLARI */
.mobile-navbar-icons {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-left: auto;
    margin-right: 12px;
}

    .mobile-navbar-icons a,
    .mobile-search-icon {
        width: 38px;
        height: 38px;
        border-radius: 50%;
        border: none;
        background: #f3f8fb;
        color: #111;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 22px;
        text-decoration: none;
        box-shadow: 0 5px 12px rgba(0,0,0,0.08);
    }

.mobile-search-icon {
    cursor: pointer;
}

/* MASAÜSTÜ ESKİ GÖRÜNÜME DÖNSÜN */
@media (min-width: 992px) {
    .mobile-navbar-icons {
        display: none !important;
    }

    .navbar-collapse {
        display: flex !important;
        justify-content: flex-end;
    }
}

/* MOBİL DÜZEN */
@media (max-width: 991.98px) {
    .navbar .container {
        display: flex;
        align-items: center;
    }

    .navbar-brand img {
        height: 62px !important;
        margin-right: 0 !important;
    }

    .navbar-toggler {
        margin-left: 0;
        border-radius: 10px;
        padding: 8px 10px;
    }

    .navbar-collapse {
        margin-top: 16px;
        background: #fff;
        border-radius: 18px;
        padding: 16px;
        box-shadow: 0 10px 26px rgba(0,0,0,0.08);
    }

    .navbar-nav {
        text-align: center;
        gap: 8px;
    }

        .navbar-nav .nav-link {
            font-size: 17px;
            font-weight: 600;
            border-radius: 12px;
            padding: 10px;
        }
}

/* MOBİL SEARCH BOX */
.mobile-search-box {
    display: none;
    width: 100%;
    margin-top: 10px;
    padding: 0 10px;
}

    .mobile-search-box input {
        border-radius: 12px;
        padding: 10px 14px;
        font-size: 14px;
        box-shadow: 0 5px 12px rgba(0,0,0,0.08);
    }

.mobile-search-box {
    display: none;
}

    .mobile-search-box.active {
        display: flex;
    }

@media (max-width: 991.98px) {
    .mobile-search-box {
        width: 52%;
        margin: 10px auto 0 auto;
        order: 5;
        animation: mobileSearchDown 0.22s ease;
    }

        .mobile-search-box input {
            height: 42px;
            border-radius: 999px;
            border: 1px solid rgba(30, 42, 56, 0.12);
            background: rgba(255, 255, 255, 0.95);
            padding: 8px 18px;
            font-size: 14px;
            box-shadow: 0 8px 22px rgba(0,0,0,0.08);
        }

            .mobile-search-box input:focus {
                border-color: #198754;
                box-shadow: 0 10px 26px rgba(25,135,84,0.16);
            }
}

@keyframes mobileSearchDown {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* MOBİL PROFİL DROPDOWN NET DÜZELTME */
@media (max-width: 576px) {

    .mobile-navbar-icons .dropdown {
        position: relative !important;
    }

    .mobile-navbar-icons .dropdown-menu {
        position: absolute !important;
        top: 44px !important;
        right: -8px !important;
        left: auto !important;
        width: 190px !important;
        min-width: 190px !important;
        padding: 8px !important;
        border-radius: 16px !important;
        background: #fff !important;
        border: 1px solid rgba(0,0,0,0.08) !important;
        box-shadow: 0 14px 35px rgba(0,0,0,0.16) !important;
        overflow: hidden !important;
        z-index: 99999 !important;
    }

        .mobile-navbar-icons .dropdown-menu .dropdown-item {
            width: 100% !important;
            display: block !important;
            padding: 11px 14px !important;
            font-size: 15px !important;
            line-height: 1.2 !important;
            border-radius: 10px !important;
            color: #1f2937 !important;
            text-align: left !important;
            white-space: nowrap !important;
        }

            .mobile-navbar-icons .dropdown-menu .dropdown-item.text-danger {
                color: #dc3545 !important;
            }

        .mobile-navbar-icons .dropdown-menu .dropdown-divider {
            margin: 6px -8px !important;
        }
}

/* MOBİL NAVBAR - ARAMA ÇUBUĞU ALT SATIRDA */
@media (max-width: 576px) {

    .navbar .container {
        display: flex !important;
        flex-wrap: wrap !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 8px;
    }

    .navbar-brand {
        flex: 0 0 auto;
    }

        .navbar-brand img {
            height: 58px !important;
            margin-right: 0 !important;
        }

    .mobile-navbar-icons {
        display: flex !important;
        align-items: center !important;
        gap: 10px !important;
        margin-left: auto !important;
        margin-right: 8px !important;
    }

    .mobile-search-icon {
        display: none !important;
    }

    .navbar-toggler {
        flex: 0 0 auto;
        margin-left: 0 !important;
        width: 48px;
        height: 48px;
        border-radius: 12px;
    }

    .mobile-search-box {
        display: block !important;
        order: 10;
        width: 70%;
        margin: 6px auto 0 auto;
    }

        .mobile-search-box input {
            height: 40px;
            border-radius: 999px;
            padding: 8px 18px;
            font-size: 14px;
            border: 1px solid rgba(30, 42, 56, 0.12);
            box-shadow: 0 8px 20px rgba(0,0,0,0.08);
        }

            .mobile-search-box input:focus {
                border-color: #198754;
                box-shadow: 0 10px 26px rgba(25,135,84,0.16);
            }
}

@media (max-width: 576px) {

    .navbar .container {
        display: flex !important;
        flex-wrap: wrap !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 8px !important;
    }

    .navbar-brand {
        order: 1;
        flex: 0 0 auto;
    }

        .navbar-brand img {
            height: 58px !important;
            margin-right: 0 !important;
        }

    .mobile-navbar-icons {
        order: 2;
        display: flex !important;
        align-items: center !important;
        gap: 10px !important;
        margin-left: auto !important;
        margin-right: 8px !important;
    }

    .navbar-toggler {
        order: 3;
        flex: 0 0 auto;
        width: 48px;
        height: 48px;
        border-radius: 12px;
        margin-left: 0 !important;
    }

    .mobile-search-icon {
        display: none !important;
    }

    .mobile-search-box {
        order: 4;
        display: block !important;
        width: 68% !important;
        margin: -4px auto 0 auto !important;
    }

        .mobile-search-box input {
            height: 40px !important;
            border-radius: 999px !important;
            padding: 8px 18px !important;
            font-size: 14px !important;
            border: 1px solid rgba(30, 42, 56, 0.14) !important;
            background: #fff !important;
            box-shadow: 0 8px 20px rgba(0,0,0,0.08) !important;
        }

            .mobile-search-box input:focus {
                border-color: #198754 !important;
                box-shadow: 0 10px 26px rgba(25,135,84,0.16) !important;
            }

    .navbar-collapse {
        order: 5;
        width: 100%;
    }
}

.mobile-search-box {
    position: relative;
}

.mobile-search-results {
    display: none;
    position: absolute;
    top: 48px;
    left: 0;
    right: 0;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 12px 30px rgba(0,0,0,0.15);
    z-index: 9999;
    overflow: hidden;
}

.mobile-search-result-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    text-decoration: none;
    color: #1e2a38;
    border-bottom: 1px solid #eef2f7;
}

    .mobile-search-result-item:last-child {
        border-bottom: none;
    }

    .mobile-search-result-item img {
        width: 42px;
        height: 42px;
        object-fit: contain;
        border-radius: 10px;
        background: #f4f8fb;
    }

.mobile-search-result-name {
    font-weight: 700;
    font-size: 14px;
}

.mobile-search-result-price {
    font-size: 13px;
    color: #198754;
    font-weight: 700;
}

.mobile-search-empty {
    padding: 12px;
    font-size: 14px;
    color: #64748b;
}