/* Custom Dropdown Styles - Based on Dirshu Design */
/* Inspired by the dropdown design showing "מיין לפי" */

:root {
    --navy-primary: #2A466E;
    --navy-dark: #213758;
    --navy-bg-3: #162C4C;
    --dropdown-bg: #3A4A60;
    --white: #FFFFFF;
    --text-light: rgba(255, 255, 255, 0.95);
}

/* Custom Dropdown Container */
.custom-dropdown-container {
    position: relative;
    display: inline-block;
}

/* Hide default select */
.custom-dropdown-container select {
    display: none;
}

/* Custom Dropdown Button */
.custom-dropdown-trigger {
    min-width: 200px;
    padding: 14px 24px;
    background: var(--navy-primary);
    color: #FFFFFF;
    border: none;
    border-radius: 30px;
    font-size: 16px;
    font-family: 'Polin', 'Heebo', sans-serif;
    font-weight: 400;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    transition: all 0.3s ease;
    box-shadow: 0px 2px 8px rgba(0, 0, 0, 0.1);
}

.custom-dropdown-trigger:hover {
    background: var(--navy-dark);
    box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.15);
}

.custom-dropdown-trigger.open {
    background: var(--navy-dark);
    border-radius: 30px 30px 0 0;
}

.custom-dropdown-trigger .dropdown-text,
.custom-dropdown-trigger .custom-dropdown-text {
    color: #FFFFFF;
}

/* Dropdown Arrow Icon */
.custom-dropdown-arrow {
    width: 10px;
    height: 10px;
    border-left: 2px solid #FFFFFF;
    border-bottom: 2px solid #FFFFFF;
    transform: rotate(-45deg);
    transition: transform 0.3s ease;
}

.custom-dropdown-trigger.open .custom-dropdown-arrow {
    transform: rotate(135deg);
}

/* Dropdown Options List */
.custom-dropdown-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #2A466E;
    border-radius: 0 0 20px 20px;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 1000;
}

.custom-dropdown-list.open {
    max-height: 300px;
    opacity: 1;
    overflow-y: auto;
}

/* Custom Scrollbar */
.custom-dropdown-list::-webkit-scrollbar {
    width: 6px;
}

.custom-dropdown-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

.custom-dropdown-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
}

.custom-dropdown-list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* Dropdown Option Item */
.custom-dropdown-option {
    padding: 14px 24px;
    color: #FFFFFF;
    background: #2A466E;
    font-size: 15px;
    font-family: 'Polin', 'Heebo', sans-serif;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.custom-dropdown-option:last-child {
    border-bottom: none;
    border-radius: 0 0 20px 20px;
}

.custom-dropdown-option:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #FFFFFF;
}

.custom-dropdown-option.selected {
    background: rgba(216, 195, 112, 0.2);
    color: #FFFFFF;
    font-weight: 500;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .custom-dropdown-container {
        width: 100%;
    }

    .custom-dropdown-trigger {
        width: 100%;
        min-width: auto;
        padding: 10px 20px;
        font-size: 16px;
        border-radius: 25px;
    }

    .custom-dropdown-trigger.light {
        padding: 10px 20px;
        font-size: 16px;
    }

    .custom-dropdown-trigger.open {
        border-radius: 25px 25px 0 0;
    }

    .custom-dropdown-list {
        border-radius: 0 0 20px 20px;
    }

    .custom-dropdown-option {
        padding: 12px 20px;
        font-size: 16px;
    }

    .custom-dropdown-option:last-child {
        border-radius: 0 0 20px 20px;
    }
}

/* Alternative Style - Light Background for filters */
.custom-dropdown-trigger.light {
    background: var(--white);
    color: #2A466E;
    border: none;
    box-shadow: none;
}

.custom-dropdown-trigger.light:hover {
    background: #F5F5F5;
}

.custom-dropdown-trigger.light .custom-dropdown-arrow {
    border-left-color: #2A466E;
    border-bottom-color: #2A466E;
}

.custom-dropdown-trigger.light .custom-dropdown-text {
    color: #2A466E;
}

.custom-dropdown-list.light {
    background: var(--white);
    border: 1px solid #E8E8E8;
    border-top: none;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
}

.custom-dropdown-option.light {
    color: #2A466E;
    background: white;
    border-bottom: 1px solid #F0F0F0;
}

.custom-dropdown-option.light:hover {
    background: #F8F8F8;
}

.custom-dropdown-option.light.selected {
    background: rgba(42, 70, 110, 0.08);
    font-weight: 500;
}
