/* Sembunyikan menu desktop di mobile, tampilkan bar bawah */

@media (max-width: 991px) {
    .desktop-menu {
        display: none !important;
    }

    .bottom-nav {
        display: flex !important;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        will-change: transform;
        height: 65px;
        background-color: #ffffff;
        border-top: 1px solid #eee;
        z-index: 1050;
        justify-content: space-around;
        align-items: center;
        padding-bottom: env(safe-area-inset-bottom);
        /* Support iPhone notch */
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
        -webkit-transform: translateZ(0);
        transform: translateZ(0);
        backface-visibility: hidden;
        perspective: 1000;
        display: flex !important;
        transform: translate3d(0, 0, 0);
        -webkit-transform: translate3d(0, 0, 0);
    }

    .bottom-nav-item {
        text-align: center;
        color: #666;
        text-decoration: none;
        flex: 1;
        display: flex;
        /* Tetap pakai flex */
        flex-direction: column;
        /* Biar icon dan teks atas-bawah */
        align-items: center;
        /* Biar semua ke tengah */
        justify-content: center;
        /* Biar seimbang atas-bawahnya */
        -webkit-tap-highlight-color: transparent;
        outline: none;
        transition: color 0.3s ease;
    }

    .bottom-nav-item i {
        font-size: 18px;
        /* Ukuran icon yang mantap */
        margin-bottom: 2px;
        /* Jarak tipis antara icon dan teks */
        line-height: 1;
        /* Biar gak ada spasi tambahan */
    }

    .bottom-nav-item span {
        font-size: 10px;
        font-weight: 500;
        letter-spacing: 0.3px;
        display: block;
        /* Memastikan teks ada di baris baru */
    }

    .bottom-nav-item.active {
        color: #dd5c36 !important;
        /* Gunakan kode warna utama Mama */
        font-weight: bold;
    }

    .bottom-nav-item.active i {
        transform: scale(0.95);
        transition: transform 0.1s;
        color: #dd5c36 !important;
    }
}

@media (min-width: 992px) {
    .bottom-nav {
        display: none !important;
    }
}

@media (max-width: 991px) {

    /* Kasih garis tipis di atas menu profil kalau di mobile */
    .border-top-mobile {
        border-top: 1px solid #eee;
        padding-top: 15px;
        width: 100%;
    }

    /* Biar dropdown user-nya nggak melayang jauh di mobile */
    #navbarMenu .dropdown-menu {
        text-align: center;
        background: #fdfdfd;
    }
}

@media (max-width: 991px) {

    /* Menghilangkan background putih dropdown di mobile agar menyatu dengan menu */
    .d-lg-none .dropdown-item {
        background: transparent !important;
        text-align: center;
        font-size: 1rem;
        padding: 12px;
    }

    .mobile-user-box {
        background: #fdfdfd;
        border-radius: 15px;
        padding: 20px 10px;
        border: 1px solid #eee;
        margin-bottom: 20px;
    }
}

.transition-all {
    transition: all 0.2s ease-in-out;
    border-radius: 12px;
}

.hover-recipe-btn:hover {
    background-color: #fff0ec;
    /* Warna soft main Mama */
    transform: scale(1.02);
}

.two-line-ellipsis {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    /* Angka baris yang diinginkan */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    /* Kadang butuh ini supaya flex child tidak melebar */
    word-break: break-word;
}

/* --- GAYA KHUSUS DESKTOP (Hover) --- */
@media (min-width: 992px) {
  .recipe-hover:hover>.clean-dropdown {
    display: block;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .clean-dropdown {
    display: block;
    /* Kita kontrol pakai opacity & visibility */
    position: absolute;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    top: 100%;
    left: 0;
    right: auto;
    z-index: 1000;
  }

  /* Menghilangkan panah dropdown di desktop kalau Mama mau lebih clean */
  .dropdown-toggle::after {
    display: none;
  }
  .clean-dropdown.dropdown-menu-right {
    left: auto !important;
    right: 0 !important;
  }
}

/* Badge Variasi */
.badge-soft-main2 {
    background: #FFF0EC;
    color: #ff6b6b;
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 5px;
}

.badge-soft-video {
    background: #E8F0FE;
    color: #4285F4;
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 5px;
}

/* Hover Effect */
.hover-bg-light:hover {
    background-color: #f8f9fa;
    transform: translateX(5px);
}

.transition-all {
    transition: all 0.3s ease;
}

.play-icon-overlay {
    /* 1. Posisi harus Absolute agar melayang di atas gambar */
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    /* 2. JURUS SAKTI: Flexbox buat naruh konten di tengah */
    display: flex;
    align-items: center;    /* Center Vertikal */
    justify-content: center; /* Center Horizontal */

    /* 3. Estetika (Background hitam transparan tipis) */
    background: rgba(0, 0, 0, 0.2); 
    border-radius: 8px; /* Samakan dengan rounded gambar */
    pointer-events: none; /* Biar tetap bisa diklik gambarnya */
}

/* Biar ikonnya ada lingkarannya sedikit */
.play-icon-overlay i {
    background: rgba(255, 69, 69, 0.8); /* Warna merah main2 Mama */
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 18px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

/* Recipe Card */
.recipe-card-simple {
    background: #fdfdfd;
    border: 1px solid #f1f1f1;
    border-radius: 12px;
    transition: all 0.2s;
}

.recipe-card-simple:hover {
    background: #FFF9E6;
    border-color: #ffe69c;
}

.icon-box-recipe {
    background: #ff6b6b;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.font-smaller { font-size: 11px; }
.small-caps { text-transform: uppercase; letter-spacing: 0.5px; font-size: 11px; }

.text-line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 3; /* 🟢 Batasi maksimal 2 baris */
    -webkit-box-orient: vertical;  
    overflow: hidden;
    white-space: normal; /* 🟢 Pastikan teks mau turun ke bawah */
}
.progress-bar {
    transition: width 0.5s ease-in-out; /* Biar bar-nya jalan halus pas dibuka */
}