/* ====================================
   القوائم المنسدلة - مضغوطة جداً
   Arab Archery
   ==================================== */

.variations select {
    display: none !important;
}

.variations.enhanced select {
    display: none !important;
}

.custom-dropdown-container {
    position: relative;
    margin-bottom: 2px;  /* ✅ مسافة معقولة */
    width: 100% !important;
    max-width: 100% !important;
}

.custom-dropdown-label {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 2px;
    font-size: 18px;
    font-weight: 700;
    color: #00BFFF;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.custom-dropdown-label::before {
    content: '';
    width: 3px;
    height: 14px;
    background: #00BFFF;
    border-radius: 2px;
}

/* الزر - أقصر ارتفاع */
.custom-dropdown-button {
    width: 100% !important;
    padding: 10px 40px 10px 14px;  /* ✅ أصغر بكثير */
    background: white;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 17px;  /* ✅ مناسب */
    font-weight: 500;
    color: #333;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: right;
    line-height: 1.3;
    min-height: 30px;  /* ✅ أقصر من 55 */
}

.custom-dropdown-button:hover {
    border-color: #00BFFF;
    box-shadow: 0 2px 8px rgba(0, 191, 255, 0.15);
}

.custom-dropdown-button.active {
    border-color: #00BFFF;
    box-shadow: 0 0 0 3px rgba(0, 191, 255, 0.08);
}

.custom-dropdown-button.placeholder .custom-dropdown-button-text {
    color: #999;
    font-style: italic;
}

.custom-dropdown-button-text {
    flex: 1;
    text-align: right;
    padding-left: 8px;
}

.custom-dropdown-arrow {
    width: 18px;
    height: 18px;
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.custom-dropdown-button.active .custom-dropdown-arrow {
    transform: rotate(180deg);
}

/* القائمة المنسدلة */
.custom-dropdown-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    width: 100% !important;
    background: white;
    border: 2px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    max-height: 280px;
    overflow-y: auto;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-5px);
    transition: all 0.2s ease;
}

.custom-dropdown-menu.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* البحث - مضغوط جداً */
.custom-dropdown-search {
    padding: 8px;  /* ✅ أصغر من 12 */
    border-bottom: 1px solid #eee;
    position: sticky;
    top: 0;
    background: white;
    z-index: 10;
}

.custom-dropdown-search input {
    width: 100%;
    padding: 2px 4px;  /* ✅ أصغر بكثير */
    border: 2px solid #ddd;
    border-radius: 6px;
    font-size: 18px;
    height: 12px;  /* ✅ ارتفاع محدد صغير */
}

.custom-dropdown-search input:focus {
    outline: none;
    border-color: #00BFFF;
}

/* الخيارات - مضغوطة */
.custom-dropdown-option {
    padding: 10px 14px;  /* ✅ أصغر من 14 */
    cursor: pointer;
    transition: all 0.15s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-right: 3px solid transparent;
    font-size: 16px;  /* ✅ مناسب */
    line-height: 1.4;
    min-height: 40px;  /* ✅ أقصر من 52 */
}

.custom-dropdown-option-text {
    flex: 1;
    text-align: right;
    padding-left: 8px;
}

.custom-dropdown-option:hover {
    background: #f0f9ff;
    border-right-color: #00BFFF;
}

.custom-dropdown-option.selected {
    background: #e6f7ff;
    border-right-color: #00BFFF;
    font-weight: 600;
    color: #00BFFF;
}

.custom-dropdown-option-check {
    width: 18px;
    height: 18px;
    opacity: 0;
    transition: opacity 0.2s;
    flex-shrink: 0;
}

.custom-dropdown-option.selected .custom-dropdown-option-check {
    opacity: 1;
}

.custom-dropdown-menu::-webkit-scrollbar {
    width: 5px;
}

.custom-dropdown-menu::-webkit-scrollbar-thumb {
    background: #00BFFF;
    border-radius: 10px;
}

.single-product .variations {
    width: 100% !important;
}

.single-product .variations tr {
    width: 100% !important;
}

.single-product .variations .value {
    width: 100% !important;
}

@media (max-width: 768px) {
    .custom-dropdown-container {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        margin-bottom: 2px;
    }
    
    .custom-dropdown-button {
        width: 100% !important;
        padding: 12px 45px 12px 14px;
        font-size: 17px;
        min-height: 48px;
    }
    
    .custom-dropdown-menu {
        width: 100% !important;
        left: 0 !important;
        right: 0 !important;
        max-height: 300px;
    }
    
    .custom-dropdown-option {
        padding: 12px 14px;
        font-size: 16px;
        min-height: 44px;
    }
    
    .custom-dropdown-search {
        padding: 8px;
    }
    
    .custom-dropdown-search input {
        font-size: 16px;
        padding: 8px 12px;
        height: 38px;
    }
    
    .single-product .variations {
        width: 100vw !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
    
    .single-product .variations tr {
        width: 100% !important;
        display: flex !important;
        flex-direction: column !important;
    }
    
    .single-product .variations .label,
    .single-product .variations .value {
        width: 100% !important;
        max-width: 100% !important;
        display: block !important;
    }
}