/* WP Mobile Bottom Menu Styles */

/* Google Fonts */
@import url("https://fonts.googleapis.com/css2?family=Varela+Round&display=swap");

/* Temel stiller */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Varela Round", sans-serif;
    -webkit-tap-highlight-color: transparent;
}

/* Mobil menü ana container */
.wp-mobile-bottom-menu {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 9999; /* Ana menü her zaman üstte */
    padding: 16px;
    max-width: 500px;
    margin: 0 auto;
}

/* Menü kutusu */
.nav-box {
    display: flex;
    padding: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    border-radius: 16px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Menü container */
.nav-container {
    display: flex;
    width: 100%;
    list-style: none;
    justify-content: space-around;
    align-items: center;
    margin: 0;
    padding: 0;
}

/* Menü öğesi */
.nav__item {
    display: flex;
    position: relative;
    padding: 4px;
    transition: all 0.3s ease;
}

.nav__item.active {
    transform: translateY(-8px);
}

.nav__item.active .nav__item-icon {
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.4);
    transform: scale(1.1);
}

.nav__item.active .nav__item-text {
    transform: scale(1);
    opacity: 1;
    color: #fff;
    font-weight: 600;
}

/* Menü link */
.nav__item-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

.nav__item-link:hover {
    color: #fff;
    text-decoration: none;
}

/* Menü ikonu */
.nav__item-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4em;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    height: 48px;
    width: 48px;
    transition: all 0.3s ease;
    position: relative;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.nav__item-icon i {
    color: #fff;
    transition: all 0.3s ease;
}

/* Badge (sepet sayısı) */
.nav__item-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: #fff;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: bold;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.4);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes pulse-animation {
    0% {
        transform: scale(1);
        box-shadow: 0 2px 8px rgba(255, 107, 107, 0.4);
    }
    50% {
        transform: scale(1.2);
        box-shadow: 0 4px 16px rgba(255, 107, 107, 0.6);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 2px 8px rgba(255, 107, 107, 0.4);
    }
}

.pulse-animation {
    animation: pulse-animation 0.6s ease-out;
}

/* Menü metni */
.nav__item-text {
    position: absolute;
    bottom: -25px;
    transform: scale(1);
    transition: all 0.3s ease;
    font-size: 11px;
    font-weight: 500;
    opacity: 1;
    white-space: nowrap;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    color: rgba(255, 255, 255, 0.8);
}

/* Sayfa alt boşluğu */
.mobile-menu-spacer {
    height: 100px;
    width: 100%;
}

/* Hesap alt menüsü */
.account-submenu {
    position: fixed;
    bottom: -100vh; /* Tamamen gizli */
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px 20px 0 0;
    padding: 20px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 9998; /* Ana menüden düşük z-index */
    max-width: 500px;
    margin: 0 auto;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    pointer-events: none; /* Varsayılan olarak tıklanamaz */
    opacity: 0; /* Varsayılan olarak şeffaf */
    visibility: hidden; /* Varsayılan olarak gizli */
}

.account-submenu.active {
    bottom: 0;
    pointer-events: auto; /* Aktif olduğunda tıklanabilir */
    opacity: 1; /* Aktif olduğunda görünür */
    visibility: visible; /* Aktif olduğunda görünür */
}

/* Alt menü başlığı */
.submenu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.submenu-header span {
    color: #fff;
    font-size: 18px;
    font-weight: 600;
}

.submenu-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submenu-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.submenu-close i {
    font-size: 18px;
}

/* Alt menü öğeleri */
.submenu-items {
    list-style: none;
    margin: 0;
    padding: 0;
}

.submenu-item {
    margin-bottom: 10px;
}

.submenu-link {
    display: flex;
    align-items: center;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.submenu-link:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateX(5px);
    color: #fff;
    text-decoration: none;
}

.submenu-link i {
    font-size: 20px;
    margin-right: 15px;
    width: 24px;
    text-align: center;
}

.submenu-link span {
    font-size: 16px;
    font-weight: 500;
}

/* Çıkış linki */
.logout-link {
    background: linear-gradient(135deg, #ff6b6b, #ee5a24) !important;
    border: none !important;
}

.logout-link:hover {
    background: linear-gradient(135deg, #ff5252, #d63031) !important;
}

/* Responsive tasarım */
@media (max-width: 480px) {
    .wp-mobile-bottom-menu {
        padding: 12px;
    }
    
    .nav-box {
        padding: 6px;
        border-radius: 12px;
    }
    
    .nav__item-icon {
        height: 44px;
        width: 44px;
        font-size: 1.3em;
    }
    
    .nav__item-text {
        font-size: 10px;
        bottom: -22px;
    }
    
    .account-submenu {
        padding: 15px;
        border-radius: 16px 16px 0 0;
    }
    
    .submenu-link {
        padding: 12px;
    }
    
    .submenu-link i {
        font-size: 18px;
        margin-right: 12px;
    }
    
    .submenu-link span {
        font-size: 14px;
    }
}

/* Tablet için */
@media (min-width: 481px) and (max-width: 768px) {
    .wp-mobile-bottom-menu {
        padding: 20px;
    }
    
    .nav-box {
        padding: 10px;
        border-radius: 18px;
    }
    
    .nav__item-icon {
        height: 52px;
        width: 52px;
        font-size: 1.5em;
    }
}

/* Desktop'ta gizle */
@media (min-width: 769px) {
    .wp-mobile-bottom-menu {
        /* Desktop'ta da görünür kalacak */
        display: block;
    }
    
    .mobile-menu-spacer {
        /* Desktop'ta da görünür kalacak */
        display: block;
    }
}

/* Animasyonlar */
@keyframes slideInUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Menü yükleme animasyonu */
.wp-mobile-bottom-menu {
    animation: slideInUp 0.6s ease-out;
}

.nav__item {
    animation: fadeIn 0.5s ease-out;
    animation-fill-mode: both;
}

.nav__item:nth-child(1) { animation-delay: 0.1s; }
.nav__item:nth-child(2) { animation-delay: 0.2s; }
.nav__item:nth-child(3) { animation-delay: 0.3s; }
.nav__item:nth-child(4) { animation-delay: 0.4s; }
.nav__item:nth-child(5) { animation-delay: 0.5s; }

/* Hover efektleri */
.nav__item:hover .nav__item-icon {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(255, 255, 255, 0.2);
}

.nav__item:hover .nav__item-text {
    transform: scale(1);
    opacity: 1;
}

/* Aktif durum animasyonu */
.nav__item.active .nav__item-icon {
    animation: activePulse 2s infinite;
}

@keyframes activePulse {
    0%, 100% {
        box-shadow: 0 8px 25px rgba(255, 107, 107, 0.4);
    }
    50% {
        box-shadow: 0 8px 35px rgba(255, 107, 107, 0.6);
    }
}

/* Loading durumu */
.nav__item.loading .nav__item-icon {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Dark mode desteği */
@media (prefers-color-scheme: dark) {
    .nav-box {
        background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    }
    
    .account-submenu {
        background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    }
}

/* Erişilebilirlik */
.nav__item-link:focus {
    outline: 2px solid rgba(255, 255, 255, 0.5);
    outline-offset: 2px;
}

.submenu-link:focus {
    outline: 2px solid rgba(255, 255, 255, 0.5);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .wp-mobile-bottom-menu,
    .mobile-menu-spacer {
        display: none !important;
    }
} 