/* Products Dropdown - Premium Enhanced Design */
/* Ultra-professional layout with advanced styling */

/* ========== DROPDOWN TRIGGER ========== */

.dropdown-trigger {
    position: relative !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.dropdown-trigger:hover {
    color: var(--main-color, #fcb700) !important;
}

.dropdown-trigger::after {
    content: '\f078' !important;
    font-family: 'Font Awesome 6 Free' !important;
    font-weight: 900 !important;
    margin-left: 6px !important;
    transition: transform 0.3s ease !important;
    color: var(--main-color, #fcb700) !important;
    font-size: 11px !important;
}

.dropdown-trigger:hover::after {
    transform: rotate(180deg) !important;
}

/* ========== DROPDOWN CONTAINER ========== */

.products-dropdown {
    position: fixed !important;
    top: 140px !important;
    left: 50% !important;
    transform: translateX(-50%) translateY(-15px) scale(0.98) !important;
    width: 900px !important;
    max-height: 650px !important;
    background: #ffffff !important;
    border-radius: 16px !important;
    box-shadow:
        0 25px 70px rgba(0, 0, 0, 0.18),
        0 10px 30px rgba(0, 0, 0, 0.12),
        0 0 0 1px rgba(0, 0, 0, 0.04) !important;
    z-index: 1000 !important;
    opacity: 0 !important;
    visibility: hidden !important;
    transition: all 0.45s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
    overflow: hidden !important;
    display: flex !important;
    flex-direction: column !important;
}

.products-dropdown.active {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateX(-60%) translateY(7%) scale(1) !important;
}

.products-dropdown::before {
    content: '' !important;
    position: absolute !important;
    top: -7px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    width: 0 !important;
    height: 0 !important;
    border-left: 10px solid transparent !important;
    border-right: 10px solid transparent !important;
    border-bottom: 10px solid var(--main-color, #fcb700) !important;
    filter: drop-shadow(0 -3px 4px rgba(0, 0, 0, 0.08)) !important;
    z-index: 11 !important;
}

.dropdown-content {
    padding: 0;
    position: relative;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}

/* Custom Scrollbar - Premium Style */
.dropdown-content::-webkit-scrollbar {
    width: 10px;
}

.dropdown-content::-webkit-scrollbar-track {
    background: linear-gradient(180deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 0 0 16px 0;
}

.dropdown-content::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--main-color, #fcb700) 0%, #f9a825 100%);
    border-radius: 5px;
    border: 2px solid #f8f9fa;
}

.dropdown-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #f9a825 0%, #e0a600 100%);
}

/* ========== DROPDOWN HEADER ========== */

.dropdown-header {
    background: linear-gradient(135deg, var(--main-color, #fcb700) 0%, #f9a825 50%, #ff9800 100%);
    color: #ffffff;
    padding: 28px 35px;
    text-align: center;
    position: sticky;
    top: 0;
    z-index: 10;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(252, 183, 0, 0.2);
}

.dropdown-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 25% 40%, rgba(255, 255, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 75% 60%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    animation: headerShimmer 4s ease-in-out infinite;
}

@keyframes headerShimmer {

    0%,
    100% {
        opacity: 0.7;
    }

    50% {
        opacity: 1;
    }
}

.dropdown-header h3 {
    margin: 0 0 10px 0;
    font-size: 26px;
    font-weight: 800;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    position: relative;
    letter-spacing: 0.3px;
}

.dropdown-header p {
    margin: 0;
    font-size: 15px;
    opacity: 0.95;
    position: relative;
    font-weight: 500;
}

/* ========== CATEGORIES GRID ========== */

.categories-grid {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 0 !important;
    padding: 0 !important;
    background: linear-gradient(135deg, #fafafa 0%, #f5f5f5 100%) !important;
}

.category-item {
    background: #ffffff !important;
    border-right: 1px solid #e5e5e5 !important;
    border-bottom: 1px solid #e5e5e5 !important;
    padding: 28px 24px !important;
    cursor: pointer !important;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1) !important;
    position: relative !important;
}

.category-item:nth-child(3n) {
    border-right: none !important;
}

.category-item:nth-last-child(-n+3) {
    border-bottom: none !important;
}

.category-item::before {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 4px !important;
    height: 100% !important;
    background: linear-gradient(180deg, var(--main-color, #fcb700) 0%, #f9a825 100%) !important;
    transform: scaleY(0) !important;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.category-item::after {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    background: linear-gradient(135deg, rgba(252, 183, 0, 0.03) 0%, transparent 100%) !important;
    opacity: 0 !important;
    transition: opacity 0.35s ease !important;
}

.category-item:hover {
    background: #ffffff !important;
    transform: translateX(4px) !important;
    box-shadow: -4px 0 12px rgba(252, 183, 0, 0.08) !important;
}

.category-item:hover::before {
    transform: scaleY(1) !important;
}

.category-item:hover::after {
    opacity: 1 !important;
}

/* ========== CATEGORY HEADER ========== */

.category-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 20px;
    position: relative;
}

.category-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 22px;
    flex-shrink: 0;
    box-shadow:
        0 6px 16px rgba(0, 0, 0, 0.18),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.category-icon::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.25) 50%, transparent 70%);
    transform: rotate(45deg);
    transition: transform 0.6s ease;
}

.category-item:hover .category-icon {
    transform: scale(1.12) rotate(-8deg);
    box-shadow:
        0 8px 20px rgba(0, 0, 0, 0.22),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.category-item:hover .category-icon::before {
    transform: rotate(45deg) translate(50%, 50%);
}

.category-info {
    flex: 1;
}

.category-info h4 {
    margin: 0 0 5px 0;
    font-size: 17px;
    font-weight: 700;
    color: var(--dark-color, #222222);
    line-height: 1.3;
    transition: all 0.3s ease;
    letter-spacing: 0.2px;
}

.category-item:hover .category-info h4 {
    color: var(--main-color, #fcb700);
    transform: translateX(2px);
}

.category-info p {
    margin: 0;
    font-size: 13px;
    color: var(--parg-color, #666666);
    line-height: 1.5;
    font-weight: 400;
}

.product-count {
    background: linear-gradient(135deg, var(--main-color, #fcb700) 0%, #f9a825 100%);
    color: #ffffff;
    padding: 4px 12px;
    border-radius: 14px;
    font-size: 11px;
    font-weight: 700;
    display: inline-block;
    margin-top: 8px;
    box-shadow: 0 3px 8px rgba(252, 183, 0, 0.35);
    letter-spacing: 0.3px;
}

/* ========== CATEGORY PRODUCTS ========== */

.category-products {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.product-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 10px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    background: linear-gradient(135deg, #fafafa 0%, #f8f8f8 100%);
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
}

.product-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, var(--main-color, #fcb700) 0%, #f9a825 100%);
    transform: scaleY(0);
    transition: transform 0.3s ease;
    border-radius: 0 3px 3px 0;
}

.product-item:hover {
    background: #ffffff;
    transform: translateX(6px);
    border-color: rgba(252, 183, 0, 0.25);
    box-shadow: 0 6px 16px rgba(252, 183, 0, 0.12);
}

.product-item:hover::before {
    transform: scaleY(1);
}

.product-image {
    position: relative;
    width: 55px;
    height: 55px;
    border-radius: 10px;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.12);
    transition: all 0.3s ease;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-item:hover .product-image {
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
    transform: scale(1.05);
}

.product-item:hover .product-image img {
    transform: scale(1.15);
}

.featured-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: linear-gradient(135deg, var(--main-color, #fcb700) 0%, #ff9800 100%);
    color: #ffffff;
    font-size: 9px;
    padding: 3px 6px;
    border-radius: 8px;
    font-weight: 700;
    box-shadow: 0 3px 8px rgba(252, 183, 0, 0.45);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.product-info {
    flex: 1;
    min-width: 0;
}

.product-info h5 {
    margin: 0 0 4px 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--dark-color, #222222);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.product-item:hover .product-info h5 {
    color: var(--main-color, #fcb700);
}

.product-price {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: var(--main-color, #fcb700);
    display: flex;
    align-items: center;
    gap: 5px;
}

.product-price::before {
    content: '';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 11px;
    opacity: 0.75;
}

/* ========== VIEW MORE ========== */

.view-more {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #e5e5e5;
    text-align: center;
}

.view-more a {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--main-color, #fcb700);
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.3s ease;
    padding: 7px 14px;
    border-radius: 8px;
    background: rgba(252, 183, 0, 0.06);
    border: 1px solid rgba(252, 183, 0, 0.15);
}

.view-more a:hover {
    background: rgba(252, 183, 0, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(252, 183, 0, 0.15);
}

.view-more i {
    font-size: 11px;
    transition: transform 0.3s ease;
}

.view-more a:hover i {
    transform: translateX(3px);
}

/* ========== DROPDOWN FOOTER ========== */

.dropdown-footer {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 24px;
    text-align: center;
    border-top: 1px solid #e0e0e0;
    position: sticky;
    bottom: 0;
    z-index: 10;
    flex-shrink: 0;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.04);
}

.view-all-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(135deg, var(--main-color, #fcb700) 0%, #f9a825 50%, #ff9800 100%);
    color: #ffffff;
    padding: 16px 36px;
    border-radius: 28px;
    text-decoration: none;
    font-weight: 700;
    font-size: 15px;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow:
        0 8px 24px rgba(252, 183, 0, 0.35),
        0 4px 12px rgba(252, 183, 0, 0.25);
    border: none;
    position: relative;
    overflow: hidden;
}

.view-all-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s ease;
}

.view-all-btn:hover::before {
    left: 100%;
}

.view-all-btn:hover {
    background: linear-gradient(135deg, var(--dark-color, #222222) 0%, #333333 100%);
    transform: translateY(-3px);
    box-shadow:
        0 12px 32px rgba(0, 0, 0, 0.3),
        0 6px 16px rgba(0, 0, 0, 0.2);
}

.view-all-btn i {
    font-size: 17px;
    transition: transform 0.3s ease;
}

.view-all-btn:hover i {
    transform: scale(1.15);
}

/* ========== ANIMATIONS ========== */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.category-item {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    opacity: 0;
}

.category-item:nth-child(1) {
    animation-delay: 0.06s;
}

.category-item:nth-child(2) {
    animation-delay: 0.12s;
}

.category-item:nth-child(3) {
    animation-delay: 0.18s;
}

.category-item:nth-child(4) {
    animation-delay: 0.24s;
}

.category-item:nth-child(5) {
    animation-delay: 0.30s;
}

.category-item:nth-child(6) {
    animation-delay: 0.36s;
}

/* ========== RESPONSIVE DESIGN ========== */

@media (max-width: 1200px) {
    .products-dropdown {
        width: 850px;
    }
}

@media (max-width: 950px) {
    .products-dropdown {
        width: 750px;
    }
}

@media (max-width: 992px) {
    .products-dropdown {
        width: 90vw;
    }

    .categories-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .category-item:nth-child(2n) {
        border-right: none !important;
    }
}

@media (max-width: 768px) {
    .products-dropdown {
        width: 95vw;
        max-height: 550px !important;
    }

    .dropdown-header {
        padding: 22px 25px;
    }

    .dropdown-header h3 {
        font-size: 22px;
    }

    .categories-grid {
        grid-template-columns: 1fr !important;
    }

    .category-item {
        border-right: none !important;
        padding: 24px 20px !important;
    }

    .category-icon {
        width: 46px;
        height: 46px;
        font-size: 20px;
    }

    .category-info h4 {
        font-size: 16px;
    }

    .product-image {
        width: 50px;
        height: 50px;
    }

    .product-info h5 {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .dropdown-header {
        padding: 20px;
    }

    .dropdown-header h3 {
        font-size: 20px;
    }

    .category-item {
        padding: 20px 16px !important;
    }

    .category-icon {
        width: 42px;
        height: 42px;
        font-size: 18px;
    }

    .category-info h4 {
        font-size: 15px;
    }

    .product-item {
        padding: 9px 10px;
    }

    .product-image {
        width: 45px;
        height: 45px;
    }

    .view-all-btn {
        padding: 14px 28px;
        font-size: 14px;
    }
}

/* ========== ACCESSIBILITY ========== */

.dropdown-trigger:focus,
.product-item:focus,
.view-more a:focus,
.view-all-btn:focus {
    outline: 3px solid var(--main-color, #fcb700);
    outline-offset: 3px;
}